The OpenD Programming Language

KeyEvent

Keyboard press and release events.

Members

Static functions

parse
KeyEvent parse(const(char)[] name, bool* ignoreModsOut, int* updown)

Parse string into key name with modifiers. It accepts things like:

Variables

charsPossible
dchar[] charsPossible;

A view into the upcoming buffer holding coming character events that are sent if and only if neither the alt or super modifier keys are pressed (check this with !(modifierState & (ModifierState.window | ModifierState.alt)) to predict if char events are actually coming..

hardwareCode
ubyte hardwareCode;

A platform and hardware specific code for the key

key
Key key;

see table below. Always use the symbolic names, even for ASCII characters, since the actual numbers vary across platforms. See Key

modifierState
uint modifierState;

see enum ModifierState. They are bitwise combined together.

pressed
bool pressed;

true if the key was just pressed, false if it was just released. note: released events aren't always sent...

window
SimpleWindow window;

associated Window

Meta