XkbKeyNumSyms(3)

πŸ’– NAME πŸ’–

okay so bestie, welcome to the XkbKeyNumSyms(3) page from XKB FUNCTIONS β€” this one is all about the function that returns the total number of keysyms for the key corresponding to keycode. ✨

πŸŽ€ SYNOPSIS πŸŽ€

int XkbKeyNumSyms (XkbDescPtr xkb, KeyCode keycode);

πŸ¦‹ ARGUMENTS πŸ¦‹

  • xkb β€” Xkb description of interest. literally the Xkb description you care about.
  • keycode β€” keycode of interest. the keycode you’re checking.

🌸 DESCRIPTION 🌸

okay so picture this: the key width and number of groups associated with a key are used to form a small two-dimensional array of KeySyms for a key. it’s giving tiny key-specific grid, and that array may be different sizes for different keys. no cap. 🫢

The array for a single key is stored as a linear list, in row-major order. The arrays for all of the keys are stored in the syms field of the client map. There is one row for each group associated with a key and one column for each level.

The index corresponding to a given group and shift level is computed as:

idx = group_index * key_width + shift_level

The offset field of the key_sym_map entry for a key is used to access the beginning of the array. πŸ’…

XkbKeyNumSyms returns the total number of keysyms for the key corresponding to keycode. periodt. πŸ‘‘


Signed off with X Version 11, libX11 1.8.14, and the XkbKeyNumSyms(3) page; the footer has no separate date, so that’s the exact version vibe we’re leaving you with. πŸŽ€

πŸ“¦ where this page comes from