[vtkusers] QVTKWidget and setCursor()
(Samuel) Byeongjun Park
byeongjun.park at case.edu
Wed May 5 11:33:20 EDT 2010
I found the answer.
Conclusively it doesn't matter of the vtk versions.
I started tracing my program from vtkXOpenGLRenderWindow.cxx
I found the cursor was changed by vtkOrientationMarkerWidget object.
I found that the InteractorObserver of vtkOrientationMarkerWidget kept
changing my mouse cursor
when my mouse enter into the viewport of the vtkOrientationMarkerWidget
But I wrote SetInteractiveOff() in my code. So I traced a little bit more
found SetInteractiveOff() should be followed AFTER SetInteractor() and
So, the program code should be sequenced like below
vtkOrientationMarkerWidget *pMakrer = vtkOrientationMarkerWidget::New();
May be it would be much helpful if a warning sentence in
vtkOrientationMarkerWidget is added in the
From: vtkusers-bounces at vtk.org [mailto:vtkusers-bounces at vtk.org] On Behalf
Of Clinton Stimpson
Sent: Wednesday, May 05, 2010 9:29 AM
To: vtkusers at vtk.org
Subject: Re: [vtkusers] QVTKWidget and setCursor()
On 05/05/2010 07:11 AM, (Samuel) Byeongjun Park wrote:
I found one problem related to mouse cursor.
I changed mouse cursor using QVTKWidget's setCursor() function which
is inherited from QWidget.
It works fine. One interesting thing I found is that VTK 5.0.4 works Okay
but when I upgraded to VTK5.4.2, somehow mouse cursor return to arrow
Both VTK 5.0.4 and 5.4.2 works when I change the mouse cursor using
However, for 5.4.2 when the QVTKWidget window is once hided by other window
raised to top, mouse cursor returned to arrow cursor for some QVTKWidgets
(not all the time, not all QVTKWidgets).
It never happen in 5.0.4.
I compared two versions of QVTKWidget source codes, but there was no
Is there any suggestion where I should dig?
My system is running Linux 64bit with NVidia GL library.
Perhaps the change in behavior is from vtkXOpenGLRenderWindow.cxx.
I suggest looking at where it calls XDefineCursor() to see if that causes
your cursor issues.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the vtkusers