XkbGetKeyActions(3)

XkbGetKeyActions(3) πŸ’…βœ¨

okay so bestie, this page is XkbGetKeyActions(3) from the XKB FUNCTIONS manual, and it is literally here to β€œUpdate the actions (the key_acts array) for a subset of the keys in a keyboard description.” πŸŽ€


🌸 NAME 🌸

XkbGetKeyActions β€” Update the actions (the key_acts array) for a subset of the keys in a keyboard description. periodt. πŸ’–

🫢 SYNOPSIS 🫢

Status XkbGetKeyActions (Display *dpy, unsigned int first, unsigned int
       num, XkbDescPtr xkb);

✨ ARGUMENTS ✨

Here’s the cast, and yes, every single one matters:

  • dpy β€” connection to X server. your portal to server land πŸ”Œ
  • first β€” keycode of first key of interest. where the lil key range starts πŸ‘‘
  • num β€” number of keys desired. how many keys we’re pulling into the group chat πŸ’…
  • xkb β€” pointer to keyboard description where result is stored. the place the lore gets saved 🫢

πŸ’– DESCRIPTION πŸ’–

Okay so XkbGetKeyActions sends a request to the server to obtain the actions for num keys on the keyboard starting with key first. It waits for a reply and returns the actions in the server->key_acts field of xkb. If successful, XkbGetKeyActions returns Success. The xkb parameter must be a pointer to a valid Xkb keyboard description. ✨

If the server map, in the xkb parameter, has not been allocated, XkbGetKeyActions allocates and initializes it before obtaining the actions. she’s proactive like that. πŸ’…

If the server does not have a compatible version of Xkb, or the Xkb extension has not been properly initialized, XkbGetKeyActions returns BadAccess. If num is less than 1 or greater than XkbMaxKeyCount, XkbGetKeyActions returns BadValue. If any allocation errors occur, XkbGetKeyActions returns BadAlloc. 😭

bestie, the xkb pointer has to be a valid Xkb keyboard description β€” that is not optional, okay? 🫢

πŸ’€ DIAGNOSTICS πŸ’€

  • BadAccess β€” The Xkb extension has not been properly initialized. 🚫
  • BadAlloc β€” Unable to allocate storage. πŸ’€
  • BadValue β€” An argument is out of range. πŸ™ˆ

Cute sign-off time: this page is serving X Version 11 / libX11 1.8.14 source/version energy, and the page tag is XkbGetKeyActions(3). byeee πŸ‘‹πŸ’œ

πŸ“¦ where this page comes from