[vtk-developers] QVTKRenderWindowInteractor and resizeEvent

Panagiotis Mavrogiorgos pmav99 at gmail.com
Tue Aug 30 13:40:11 EDT 2011


> Yes.  But could you instead try something like super(vtkRenderWindow,
> self._RenderWindow).SetSize(w.h) to not call the X11/Win32/etc.. code?
>

I tried to use super but vtk classes must be old-style classes, so it
results in :

TypeError: super() argument 1 must be type, not vtkclass

The following seems to work though :

vtk.vtkRenderWindow.SetSize(self._RenderWindow, w, h)

If this is ok, then the resizeEvent method perhaps could be implemented like
this:

    def resizeEvent(self,ev):
        w = self.width()
        h = self.height()
        vtk.vtkRenderWindow.SetSize(self._RenderWindow, w, h)
        self._Iren.SetSize(w, h)
        self._Iren.ConfigureEvent()
        self.update()
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtk-developers/attachments/20110830/815bda47/attachment.html>


More information about the vtk-developers mailing list