XkbGetNames(3)
β¨ XkbGetNames β¨
okay so bestie, welcome to XkbGetNames(3) β a little function from the XKB FUNCTIONS corner of the libX11 universe, and honestly? it's giving "the server has the lore and I need it" π
π NAME π
XkbGetNames β Obtain symbolic names from the server πΈ
like, it goes and gets the names. from the server. that's the whole vibe, no cap.
π¦ SYNOPSIS π¦
Status XkbGetNames (Display *dpy, unsigned int which, XkbDescPtr xkb);
π ARGUMENTS π
dpyβ your connection to the X server, iykyk π«Άwhichβ a mask of names or map components that you want to be updated β¨xkbβ the keyboard description that's gonna get updated, main character energy π
π DESCRIPTION π
so XkbGetNames retrieves symbolic names for the components of the keyboard extension from the X server, fr fr. the which parameter specifies which name components get updated inside the xkb parameter, and it's the bitwise inclusive OR of the valid names mask bits defined in Table 1, bestie π§
β Table 1 β Symbolic Names Masks β
XkbKeycodesNameMaskβ(1<<0)βXkb->namesβkeycodesXkbGeometryNameMaskβ(1<<1)βXkb->namesβgeometryXkbSymbolsNameMaskβ(1<<2)βXkb->namesβsymbolsXkbPhysSymbolsNameMaskβ(1<<3)βXkb->namesβphys_symbolsXkbTypesNameMaskβ(1<<4)βXkb->namesβtypeXkbCompatNameMaskβ(1<<5)βXkb->namesβcompatXkbKeyTypeNamesMaskβ(1<<6)βXkb->mapβtype[*].nameXkbKTLevelNamesMaskβ(1<<7)βXkb->mapβtype[*].lvl_names[*]XkbIndicatorNamesMaskβ(1<<8)βXkb->namesβindicators[*]XkbKeyNamesMaskβ(1<<9)βXkb->namesβkeys[*],num_keysXkbKeyAliasesMaskβ(1<<10)βXkb->namesβkey_aliases[*],num_key_aliasesXkbVirtualModNamesMaskβ(1<<11)βXkb->namesβvmods[*]XkbGroupNamesMaskβ(1<<12)βXkb->namesβgroups[*]XkbRGNamesMaskβ(1<<13)βXkb->namesβradio_groups[*],num_rgXkbComponentNamesMaskβ(0x3f)βXkb->namesβkeycodes,geometry,symbols, physical symbols,types, and compatibility mapXkbAllNamesMaskβ(0x3fff)βXkb->namesβ all name components
likeβ¦ that's the whole menu, and yes you can OR them together π
now for the fun part, the behavior π
if the names field of the keyboard description xkb is NULL, XkbGetNames allocates and initializes the names component of the keyboard description before obtaining the values specified by which β¨ it's literally doing setup for you, obsessed.
if the names field of xkb is not NULL, XkbGetNames obtains the values specified by which and copies them into the keyboard description Xkb π
π¨ heads up bestie: if themapcomponent of thexkbparameter isNULL,XkbGetNamesdoes not retrieve type or shift level names β even ifXkbKeyTypeNamesMaskorXkbKTLevelNamesMaskare set inwhich. like it just won't. don't come for her π
XkbGetNames can return Success, or BadAlloc, BadLength, BadMatch, and BadImplementation errors.
and when you're done with your symbolic names and you wanna free them? use XkbFreeNames π (see SEE ALSO, she's linked below, periodt)
π DIAGNOSTICS π
BadAllocβ Unable to allocate storage πBadImplementationβ Invalid reply from server πBadLengthβ The length of a request is shorter or longer than that required to minimally contain the arguments πBadMatchβ A compatible version of Xkb was not available in the server or an argument has correct type and range, but is otherwise invalid β
π₯ SEE ALSO π₯
XkbFreeNames(3)π«Ά
and that's the whole page, bestie! this iconic lil' manual page came to you straight from X Version 11, libX11 1.8.14 β go forth and get those names ππβ¨
π¦ where this page comes from
- alpine 3.24: libx11-doc 1.8.14-r0 Β· X11
- arch rolling: libx11 1.8.14-1 Β· MIT AND X11
- nixos 26.05: libx11 1.8.14
- nixpkgs unstable: libx11 1.8.14
- Copyright (c) 1999, Oracle and/or its affiliates
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms