Enum KeyMods

Keyboard modifier flags for KeyEvent.

enum KeyMods : uint { ... }

Note that on macOS, for better portability, modifiers are converted to their Windows/Linux analogs (Command to Ctrl, Option to Alt, and Control to Meta).

Enum members

NameDescription
alt Alt key (Option on macOS)
common Modifiers that don't count the difference between left or right
control Ctrl key (Command on macOS)
lalt Left Alt key (includes alt flag)
lcontrol Left Ctrl key (includes control flag)
lmeta Left Meta/Win key (includes meta flag)
lralt Both left and right Alt key
lrcontrol Both left and right Ctrl key
lrmeta Both left and right Meta key
lrshift Both left and right Shift key
lshift Left Shift key (includes shift flag)
meta Meta/Win key (Control on macOS)
none
ralt Right Alt key (includes alt flag)
rcontrol Right Ctrl key (includes control flag)
rmeta Right Meta/Win key (includes meta flag)
rshift Right Shift key (includes shift flag)
shift Shift key