[vtkusers] ALT key

Karthik Krishnan karthik.krishnan at kitware.com
Wed May 19 05:12:27 EDT 2010


control + shift is another option.. Note the modifiers are designed to be
used in combinatiton.

2010/5/19 Rodrigo Valiña Gutiérrez <rodrigo.valina at usc.es>

> Hi,
>
> It does not work.
>
> With Ctrl+Alt, GetAltKey() returns 0. Also it behaves like Ctrl,
> rotating around an axis.
>
> I was looking for a key that does not modify the regular behavior
> (rotation) of the scene...
>
> --
> Rodrigo
>
> 2010/5/19 Jérôme <jerome.velut at gmail.com>:
> > Hi,
> > The Alt key is expected to be triggered along with another key.
> > You can try a combination of ctrl+alt.
> >
> > Jerome
> >
> > 2010/5/18 Rodrigo Valiña Gutiérrez <rodrigo.valina at usc.es>:
> >> Hi,
> >>
> >> I am using VTK 5.4.2 embedded in Python + wxWidgets
> >>
> >> I am trying to capture a key that does not modify the left click
> >> action by default.
> >>
> >> I use vtkRenderWindowInteractor and its methods:
> >>
> >>        a = self.iren.GetAltKey()
> >>        c = self.iren.GetControlKey()
> >>        s = self.iren.GetShiftKey()
> >>        kc = self.iren.GetKeyCode()
> >>        ks = self.iren.GetKeySym()
> >>
> >> CTRL rotates
> >> SHIFT displaces
> >> ALT is never reported, I think that because, at least in Windows, it
> >> triggers a menu event (selects the first menu in the menubar).
> >> the KeyCode is always '\x00'
> >> the KeySym is always None
> >>
> >> looking at the code of
> >> vtkRenderWindowInteractor::SetEventInformation(), I see that AltKey is
> >> never modified.
> >>
> >> So, is there any other key that I can use to do in my code a custom
> >> action when pressing left mouse button?
> >> _______________________________________________
> >> Powered by www.kitware.com
> >>
> >> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
> >>
> >> Please keep messages on-topic and check the VTK FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
> >>
> >> Follow this link to subscribe/unsubscribe:
> >> http://www.vtk.org/mailman/listinfo/vtkusers
> >>
> >
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20100519/a956c526/attachment.htm>


More information about the vtkusers mailing list