For many functions in this section, you pass keymask bits. The valid keymask bits are: ShiftMask, LockMask, ControlMask, Mod1Mask, Mod2Mask, Mod3Mask, Mod4Mask, and Mod5Mask.
To grab the keyboard, use XGrabKeyboard().
To ungrab the keyboard, use XUngrabKeyboard().
To passively grab a single key of the keyboard, use XGrabKey().
To ungrab a key, use XUngrabKey().