Om
1.0.0
A universal framework for multimedia simulation
|
A class that represents a single key on a keyboard. More...
#include <omGUIInputKey.h>
Public Member Functions | |
Key () | |
Create a key with an undefined key code and no name. More... | |
Key (KeyCode newCode, const UTF8String &newName) | |
Create a key with the specified generic key code and name string. More... | |
KeyCode | getCode () const |
Return the integer key code for this key. More... | |
void | setCode (KeyCode newCode) |
Set the integer key code for this key. More... | |
operator KeyCode () const | |
Convert this key to an integer code. More... | |
Hash | getHashCode () const |
Return an integer hash code for this key. More... | |
const UTF8String & | getName () const |
Return a const reference to a human-readable name for this key. More... | |
void | setName (const UTF8String &newName) |
Set the human-readable name for this key. More... | |
const UTF8String & | toString () const |
Return a const reference to this key's string representation (its name). More... | |
operator UTF8String () const | |
Convert this key to a string representation (its name). More... | |
Bool | operator== (const Key &key) const |
Return whether or not this key is equal to another key. More... | |
Bool | operator!= (const Key &key) const |
Return whether or not this key is not equal to another key. More... | |
Static Public Member Functions | |
static Bool | isPressed (const Key &key) |
Return whether or not a key is currently pressed based on the global system keyboard state. More... | |
Static Public Attributes | |
static const Key | UNDEFINED |
A key that represents an undefined or invalid key. More... | |
static const Key | A |
static const Key | B |
static const Key | C |
static const Key | D |
static const Key | E |
static const Key | F |
static const Key | G |
static const Key | H |
static const Key | I |
static const Key | J |
static const Key | K |
static const Key | L |
static const Key | M |
static const Key | N |
static const Key | O |
static const Key | P |
static const Key | Q |
static const Key | R |
static const Key | S |
static const Key | T |
static const Key | U |
static const Key | V |
static const Key | W |
static const Key | X |
static const Key | Y |
static const Key | Z |
static const Key | NUMBER_0 |
static const Key | NUMBER_1 |
static const Key | NUMBER_2 |
static const Key | NUMBER_3 |
static const Key | NUMBER_4 |
static const Key | NUMBER_5 |
static const Key | NUMBER_6 |
static const Key | NUMBER_7 |
static const Key | NUMBER_8 |
static const Key | NUMBER_9 |
static const Key | QUOTE |
static const Key | COMMA |
static const Key | HYPHEN |
static const Key | PERIOD |
static const Key | SLASH |
static const Key | SEMICOLON |
static const Key | EQUALS |
static const Key | OPEN_BRACKET |
static const Key | CLOSE_BRACKET |
static const Key | BACKSLASH |
static const Key | TILDE |
static const Key | KEYPAD_0 |
static const Key | KEYPAD_1 |
static const Key | KEYPAD_2 |
static const Key | KEYPAD_3 |
static const Key | KEYPAD_4 |
static const Key | KEYPAD_5 |
static const Key | KEYPAD_6 |
static const Key | KEYPAD_7 |
static const Key | KEYPAD_8 |
static const Key | KEYPAD_9 |
static const Key | KEYPAD_PERIOD |
static const Key | KEYPAD_SLASH |
static const Key | KEYPAD_ASTERISK |
static const Key | KEYPAD_HYPHEN |
static const Key | KEYPAD_PLUS |
static const Key | KEYPAD_ENTER |
static const Key | KEYPAD_EQUALS |
static const Key | KEYPAD_COMMA |
static const Key | KEYPAD_EQUALS_AS400 |
static const Key | NUM_LOCK |
static const Key | CAPS_LOCK |
static const Key | SCROLL_LOCK |
static const Key | LEFT_SHIFT |
static const Key | RIGHT_SHIFT |
static const Key | LEFT_CONTROL |
static const Key | RIGHT_CONTROL |
static const Key | LEFT_ALT |
static const Key | RIGHT_ALT |
static const Key | LEFT_GUI |
static const Key | RIGHT_GUI |
static const Key | FUNCTION |
static const Key | LOCKING_CAPS_LOCK |
static const Key | LOCKING_NUM_LOCK |
static const Key | LOCKING_SCROLL_LOCK |
static const Key | UP_ARROW |
static const Key | DOWN_ARROW |
static const Key | LEFT_ARROW |
static const Key | RIGHT_ARROW |
static const Key | BACKSPACE |
static const Key | DELETE |
static const Key | TAB |
static const Key | CLEAR |
static const Key | RETURN |
static const Key | PAUSE |
static const Key | ESCAPE |
static const Key | SPACE |
static const Key | ALTERNATE_ERASE |
static const Key | ALTERNATE_RETURN |
static const Key | HELP |
static const Key | |
static const Key | SYS_REQ |
static const Key | MENU |
static const Key | POWER |
static const Key | UNDO |
static const Key | INSERT |
static const Key | HOME |
static const Key | END |
static const Key | PAGE_UP |
static const Key | PAGE_DOWN |
static const Key | APPLICATION |
static const Key | EXECUTE |
static const Key | SELECT |
static const Key | STOP |
static const Key | AGAIN |
static const Key | VOLUME_UP |
static const Key | VOLUME_DOWN |
static const Key | VOLUME_MUTE |
static const Key | CANCEL |
static const Key | PRIOR |
static const Key | SEPARATOR |
static const Key | OUT |
static const Key | OPERATE |
static const Key | CLEAR_OR_AGAIN |
static const Key | CR_SEL_OR_PROPS |
static const Key | EX_SEL |
static const Key | CUT |
static const Key | COPY |
static const Key | PASTE |
static const Key | FIND |
static const Key | F1 |
static const Key | F2 |
static const Key | F3 |
static const Key | F4 |
static const Key | F5 |
static const Key | F6 |
static const Key | F7 |
static const Key | F8 |
static const Key | F9 |
static const Key | F10 |
static const Key | F11 |
static const Key | F12 |
static const Key | F13 |
static const Key | F14 |
static const Key | F15 |
static const Key | F16 |
static const Key | F17 |
static const Key | F18 |
static const Key | F19 |
static const Key | F20 |
static const Key | F21 |
static const Key | F22 |
static const Key | F23 |
static const Key | F24 |
static const Key | INTERNATIONAL_1 |
static const Key | INTERNATIONAL_2 |
static const Key | INTERNATIONAL_3 |
static const Key | INTERNATIONAL_4 |
static const Key | INTERNATIONAL_5 |
static const Key | INTERNATIONAL_6 |
static const Key | INTERNATIONAL_7 |
static const Key | INTERNATIONAL_8 |
static const Key | INTERNATIONAL_9 |
static const Key | LANGUAGE_1 |
static const Key | LANGUAGE_2 |
static const Key | LANGUAGE_3 |
static const Key | LANGUAGE_4 |
static const Key | LANGUAGE_5 |
static const Key | LANGUAGE_6 |
static const Key | LANGUAGE_7 |
static const Key | LANGUAGE_8 |
static const Key | LANGUAGE_9 |
static const Key | NON_US_POUND |
static const Key | NON_US_BACKSLASH |
A class that represents a single key on a keyboard.
Each Key object has an integer key code, plus a human-readable name string for that key.
This class also provides statically-defined Key objects that encompass most types of keyboards. These objects can be queried directly as public static members or by hash table key code lookup.
|
inline |
Create a key with an undefined key code and no name.
|
inline |
Create a key with the specified generic key code and name string.
|
inline |
Return the integer key code for this key.
|
inline |
Set the integer key code for this key.
|
inline |
Convert this key to an integer code.
|
inline |
Return an integer hash code for this key.
|
inline |
Return a const reference to a human-readable name for this key.
|
inline |
Set the human-readable name for this key.
|
inline |
Return a const reference to this key's string representation (its name).
|
inline |
Convert this key to a string representation (its name).
Return whether or not this key is equal to another key.
This operator only compares the key codes.
Return whether or not this key is not equal to another key.
This operator only compares the key codes.
Return whether or not a key is currently pressed based on the global system keyboard state.
|
static |
A key that represents an undefined or invalid key.
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |