1 /*=========================================================================
2 
3   Program:   Visualization Toolkit
4   Module:    vtkTkRenderWidget.h
5 
6   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7   All rights reserved.
8   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10      This software is distributed WITHOUT ANY WARRANTY; without even
11      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12      PURPOSE.  See the above copyright notice for more information.
13 
14 =========================================================================*/
15 // .NAME vtkTkRenderWidget - a Tk Widget for vtk renderering
16 
17 // .SECTION Description
18 // vtkTkRenderWidget is a Tk widget that you can render into. It has a
19 // GetRenderWindow method that returns a vtkRenderWindow. This can then
20 // be used to create a vtkRenderer and etc. You can also specify a
21 // vtkRenderWindow to be used when creating the widget by using
22 // the -rw option. It also takes -width and -height options.
23 // Events can be bound on this widget just like any other Tk widget.
24 
25 // .SECTION See Also
26 // vtkRenderWindow vtkRenderer
27 
28 
29 #ifndef vtkTkRenderWidget_h
30 #define vtkTkRenderWidget_h
31 
32 #include "vtkRenderWindow.h"
33 #include "vtkTcl.h"
34 #include "vtkWindows.h"
35 
36 // For the moment, we are not compatible w/Photo compositing
37 // By defining USE_COMPOSITELESS_PHOTO_PUT_BLOCK, we use the compatible
38 // call.
39 #define USE_COMPOSITELESS_PHOTO_PUT_BLOCK
40 #include "vtkTk.h"
41 
42 #ifndef VTK_PYTHON_BUILD
43 #include "vtkTclUtil.h"
44 #endif
45 
46 struct vtkTkRenderWidget
47 {
48   Tk_Window  TkWin;             /* Tk window structure */
49   Tcl_Interp *Interp;           /* Tcl interpreter */
50   int Width;
51   int Height;
52   vtkRenderWindow *RenderWindow;
53   char *RW;
54 #ifdef _WIN32
55   WNDPROC OldProc;
56 #endif
57 };
58 
59 #endif
60