Hi Robert, I've just tried osgkeyboard on Mac OS X 10.6.5: whatever key I press I see that it is correctly written in yellow in the row just below the keyboard, but it is NOT highlighted on the keyboard itself. I'm talking about not only the modifiable-keys but also about keys (such as backspace, space, ...) that cannot have a modified status (at least I guess).
One note not related to this topic: I noticed that plugins are not built into the osgPlugins-2.9.11 folder but just at the same level of the dylibs. Hope this helps. Cheers. Alessandro On Thu, Jan 27, 2011 at 5:40 PM, Robert Osfield <[email protected]>wrote: > Hi OSX dev's, > > This afternoon I merged a submission from Alexander Sinditskiy, that > addressed a limitation in osgGA::GUIEventAdapter where the getKey() > method would return only the modified variation of the keycode that > was pressed - so this would be Ctrl-C, 'C' or 'c', and if your you > didn't want to worry about the modified key status you'd have to > handle each of these cases in your event code. > > The way that Alexander addressed this was to add a new UnmodifiedKey > property to GUIEventAdapter, with support added to the > osgGA::EventQueue as well as the X11 and Win32 implementations found > in GraphicsWindowX11.cpp and GraphicsWindowWin32.cpp. Alexander and > his colleagues don't have access to OSX so couldn't add the required > support into GraphicsWindowCocoa/Carbon so for now you'll just get a 0 > for the UnmofidiedKey. > > Now this won't affect most apps as they won't yet be using the > UnmodifiedKey property, but osgkeyboard has now been modified to use > the UnmodifiedKey property as this illustrates it's usage and also > simplifies the example as it no longer needs to doing multiple > mappings to handle upper and lower case letters. However, osgkeyboard > will now just get a 0 for UnmodifiedKey so the keys on screen won't > toggle on/off correctly. At least this is what I'm expecting - I > don't have on OSX box in front of me so I can't test this. > > Could OSX users try out OSG in svn/trunk and run osgkeyboard and see > how things behave and then have a look into the possibility of > providing the UmodifiedKey property as GraphicsWindowWin32.cpp and > GraphicsWindowX11.cpp now do. The unmodified keys now map the 'A' and > 'a' to be 'a', X11 is already uses this convention while Win32 have > 'A' as the unmodified state, but Alexander's revision addresses this > so both produce an GUIEventAdapter::KEY_A which is mapped to 'a'. OSX > will need to use the same convention. > > Thanks in advance with any help you can provide in adding this > functionality to OSX. > > Cheers, > Robert. > _______________________________________________ > osg-users mailing list > [email protected] > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org >
_______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

