[vtkusers] QVTK : pb with Qt designer and python

Gaetan Lehmann gaetan.lehmann at jouy.inra.fr
Thu Jan 12 11:33:46 EST 2006


On Thu, 12 Jan 2006 13:59:35 +0100, David Cole <david.cole at kitware.com>  
wrote:

> Will this patch work with all versions of Qt and Python or does it  
> require a certain minimum version of either...?

I'm not sure.
It should be tested, but I only have PyQt 3.14.1 and 3.15.1 (and it works  
for those 2 versions)

>
> Gaetan Lehmann wrote:
>
>> On Thu, 12 Jan 2006 09:43:48 +0100, Stephane PLOIX  
>> <stephane.ploix at edf.fr>  wrote:
>>
>>> Hi,
>>>
>>> I am trying to use VTK with Qt Designer and python bindings.
>>>
>>> First pb :
>>> When I create a QVTKWidget in Qt designer, compile the form with pyuic,
>>> python cannot find the QVTKWidget.
>>> When looking into the python wrapped files, it should be a
>>> QVTKRenderWidget.
>>>
>>> Second pb :
>>> I manually modify QVTKWidget into QVTKRenderWidget in the .ui or in the
>>> .py generated file, and python is happy now, until it tries to actually
>>> create the widget.
>>> in the file Wrapping/Python/vtk/qt/QVTKRenderWidget.py, line 106 :
>>> "apply(QWidget.__init__, (self,parent,name) + args, kw)"
>>> the apply function is deprecated. replacing it by
>>> QWidget.__init__.(self,parent,name) works, but this is really dirty...
>>>
>>> Is there a solution to use QVTK with Qt Designer without modifying the
>>> created python files?
>>>
>>
>> I just want to add that to be able to use vtk 5.0 with Qt in python, I   
>> have to apply the attached patch, which also fix some other errors.
>> I have already applied the patch to the mandriva cooker package, but I   
>> think it should be included in VTK tree
>>
>> Gaetan
>>
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> This is the private VTK discussion list. Please keep messages on-topic.  
>> Check the FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
>> Follow this link to subscribe/unsubscribe:
>> http://www.vtk.org/mailman/listinfo/vtkusers
>>



-- 
Gaëtan Lehmann
Biologie du Développement et de la Reproduction
INRA de Jouy-en-Josas (France)
tel: +33 1 34 65 29 66    fax: 01 34 65 29 09
http://voxel.jouy.inra.fr



More information about the vtkusers mailing list