SoWinKeyboard Class Reference
[Win]

VSG extension Translates and reports messages for the keyboard device. More...

#include <Inventor/Win/devices/SoWinKeyboard.h>

Inheritance diagram for SoWinKeyboard:
SoWinDevice

List of all members.

Public Member Functions

 SoWinKeyboard (EventMask mask=SO_WIN_ALL_KEYBOARD_EVENTS)
 ~SoWinKeyboard ()
virtual void enable (SoWidget w, XtEventHandler f, XtPointer data, Window win=NULL)
virtual void disable (SoWidget w, XtEventHandler f, XtPointer data)
virtual const SoEventtranslateEvent (XAnyEvent *xevent)

Detailed Description

VSG extension Translates and reports messages for the keyboard device.

This class translates and manages messages generated by the keyboard, including key press and release messages (SoKeyboardEvent).

SEE ALSO

SoWinDevice, SoKeyboardEvent


Constructor & Destructor Documentation

SoWinKeyboard::SoWinKeyboard ( EventMask  mask = SO_WIN_ALL_KEYBOARD_EVENTS  ) 

Constructor.

To the constructor, pass which keyboard messages you are interested in as a bitwise OR of the following values:

KeyPressMask - Key press messages

KeyReleaseMask - Key release messages

Or simply pass the defined value SO_WIN_ALL_KEYBOARD_EVENTS for all keyboard messages. The device will only report messages of this type for the window handle it is enabled on.

SoWinKeyboard::~SoWinKeyboard (  ) 

Destructor.


Member Function Documentation

virtual void SoWinKeyboard::disable ( SoWidget  w,
XtEventHandler  f,
XtPointer  data 
) [virtual]

Disables the device.

Implements SoWinDevice.

virtual void SoWinKeyboard::enable ( SoWidget  w,
XtEventHandler  f,
XtPointer  data,
Window  win = NULL 
) [virtual]

Enables the device for the passed window handle. When enabled, the callback function f will be invoked when messages occur in the window. data is the clientData which will be passed.

Implements SoWinDevice.

virtual const SoEvent* SoWinKeyboard::translateEvent ( XAnyEvent *  xevent  )  [virtual]

Attempts to convert the passed message into an SoEvent.
Returns a pointer to an internal SoEvent object owned by the class. Do not delete this object. If the message was not generated by this device, then NULL is returned.

Implements SoWinDevice.


The documentation for this class was generated from the following file:

Open Inventor Toolkit reference manual, generated on 15 Mar 2023
Copyright © Thermo Fisher Scientific All rights reserved.
http://www.openinventor.com/