ModifierType
Description:
[ CCode ( cprefix = "GDK_" , type_id = "gdk_modifier_type_get_type ()" ) ]
[ Flags ]
public enum ModifierType
A set of bit-flags to indicate the state of modifier keys and mouse buttons in various event types.
Typical modifier keys are Shift, Control, Meta, Super, Hyper, Alt, Compose, Apple, CapsLock or ShiftLock.
Like the X Window System, GDK supports 8 modifier keys and 5 mouse buttons.
Since 2.10, GDK recognizes which of the Meta, Super or Hyper keys are mapped to Mod2 - Mod5, and indicates this by setting
gdk_super_mask, gdk_hyper_mask or gdk_meta_mask
in the state field of key events.
Note that GDK may add internal values to events which include reserved values such as gdk_modifier_reserved_13_mask
. Your code should preserve and ignore them. You can use gdk_modifier_mask to remove all reserved
values.
Also note that the GDK X backend interprets button press events for button 4-7 as scroll events, so gdk_button4_mask
and gdk_button5_mask will never be set.
Content:
Enum values:
- BUTTON1_MASK - the first mouse
button.
- BUTTON2_MASK - the second mouse
button.
- BUTTON3_MASK - the third mouse
button.
- BUTTON4_MASK - the fourth mouse
button.
- BUTTON5_MASK - the fifth mouse
button.
- CONTROL_MASK - the Control key.
- HYPER_MASK - the Hyper modifier.
- LOCK_MASK - a Lock key (depending on
the modifier mapping of the X server this may either be CapsLock or ShiftLock).
- META_MASK - the Meta modifier.
- MOD1_MASK - the fourth modifier key (
it depends on the modifier mapping of the X server which key is interpreted as this modifier, but normally it is the Alt key).
- MOD2_MASK - the fifth modifier key (
it depends on the modifier mapping of the X server which key is interpreted as this modifier).
- MOD3_MASK - the sixth modifier key (
it depends on the modifier mapping of the X server which key is interpreted as this modifier).
- MOD4_MASK - the seventh modifier key
(it depends on the modifier mapping of the X server which key is interpreted as this modifier).
- MOD5_MASK - the eighth modifier key (
it depends on the modifier mapping of the X server which key is interpreted as this modifier).
- MODIFIER_MASK - a mask covering
all modifier types.
- RELEASE_MASK - not used in GDK
itself.
- SHIFT_MASK - the Shift key.
- SUPER_MASK - the Super modifier.