[vtk-developers] Disable scaling vtkBoxWidget2 on one side

Laurent Chauvin lchauvin at bwh.harvard.edu
Tue Feb 7 14:15:14 EST 2012


Hello,

I am using vtkBoxWidget2 on Slicer 3.6.
I would like to know if it's possible to disable scaling on one direction
(for example, keep scaling on x,y but not on z).

Or maybe disable the handle.

My problem is, I am setting the height of the vtkBoxWidget2 with a slider.
When the slider increment, the actual height of the box is doubled.
The slider and the box are kind of synchronized.

But if the user manually (on the 3D view) change the height of the
vtkBoxWidget2, the slider is not updated, and so they are not synchronized
anymore.

That's why I would like to prevent the user to scale on z direction.

I know there is a flag set with ScalingDisabled(), but this is disabling on
all directions. And I didn't found where is flag is used to lock the
scaling.

Does someone have an idea ?

Thank you.
-Laurent

-- 
Laurent Chauvin, MS
Surgical Navigation and Robotics Laboratory, Radiology
Brigham And Women's Hospital, Harvard Medical School
http://wiki.ncigt.org/index.php/User:Lchauvin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtk-developers/attachments/20120207/15ba9265/attachment.html>


More information about the vtk-developers mailing list