[vtk-developers] VTK Python and Tk [was: VTK Python Installation]

Brad King brad.king at kitware.com
Fri Aug 12 13:40:36 EDT 2005


David Cole wrote:
>> IF(VTK_INCLUDE_NEED_TK)
>>   # Need Tk sources on windows
>>   IF(WIN32)
>>     FIND_PATH(TK_XLIB_PATH
>>               X11/Xlib.h ${TK_INCLUDE_PATH}
>>               ${TK_INCLUDE_PATH}/../xlib)
>>     MARK_AS_ADVANCED(TK_XLIB_PATH)
>>   ENDIF(WIN32)
>>   # Need Tk headers and libraries for python TK widgets
>>   IF(NOT VTK_WRAP_TCL)
>>     VTK_INCLUDE_TCL_TK_MODULES()
>>   ENDIF(NOT VTK_WRAP_TCL)
>> ENDIF(VTK_INCLUDE_NEED_TK)
> 
> Seems to me like the FIND_PATH should be after the 
> VTK_INCLUDE_TCL_TK_MODULES

I've committed this change.

 > - or that (as has been suggested I think) a
> VTK_WRAP_PYTHON build of VTK should not be dependent on Tk if at all 
> possible...

The vtkRenderingPythonTkWidgets library needs Tk but it provides some 
nice tkinter helpers.  I agree this should not be required though.  We 
should add an option like "VTK_USE_PYTHON_TK" to select whether the 
Tk-dependent parts are provided.  It would have to default to ON to 
preserve behavior.

Any suggestions for a better name or another approach?

-Brad



More information about the vtk-developers mailing list