TERMKEY_GET_KEYNAME(3)
π NAME π
termkey_get_keyname β bestie, this one hands you a cute lil string name for a symbolic key π
β¨ SYNOPSIS β¨
#include <termkey.h>
const char *termkey_get_keyname(TermKey *tk, TermKeySym sym);
Link with -ltermkey. π«Ά
πΈ DESCRIPTION πΈ
okay so termkey_get_keyname() gives you a human-readable string name for whatever symbolic key value you pass in as sym. like, you hand it a key, it hands you back the vibe in words. iconic behavior honestly π
here's the tea though β the string it returns is owned by the termkey(7) instance tk, so do NOT modify it and do NOT free it. it's not yours, bestie, it's the instance's. π
and the pointer you get back? guaranteed valid right up until the instance gets released with termkey_destroy(3). so keep tk alive and your string stays valid, no cap. β¨
also it's literally the inverse of termkey_keyname2sym(3) β they're giving mirror, they're giving symmetry, they're giving reverse it back. π¦
π₯ RETURN VALUE π₯
termkey_get_key() returns a pointer to a string. that's it, that's the whole thing. pointer. string. periodt. π
π SEE ALSO π
k bye bestie, this was page TERMKEY_GET_KEYNAME(3) from the Library Functions Manual π go forth and name your keys, you absolute main character πβπ
π¦ where this page comes from
- alpine 3.24: libtermkey-doc 0.22-r4 Β· MIT
- debian trixie: libtermkey-dev 0.22-2+b1 Β· MIT
- epel 10: libtermkey-devel 0.22-2.el10_0 Β· MIT
- epel 9: libtermkey-devel 0.22-2.el9 Β· MIT
- fedora 43: libtermkey-devel 0.22-11.fc43 Β· MIT
- fedora 43: libtermkey-devel 0.22-11.fc43 Β· MIT
- fedora 44: libtermkey-devel 0.22-12.fc44 Β· MIT
- fedora 44: libtermkey-devel 0.22-12.fc44 Β· MIT
- nixos 26.05: libtermkey 0.22
- nixpkgs unstable: libtermkey 0.22
- opensuse-leap 16.0: libtermkey-devel 0.22-bp160.1.11 Β· MIT
- opensuse-leap 16.0: libtermkey-devel 0.22-bp160.1.11 Β· MIT
- opensuse-leap 16.0: libtermkey-devel 0.22-bp160.1.11 Β· MIT
- opensuse-leap 16.0: libtermkey-devel 0.22-bp160.1.11 Β· MIT
- ubuntu questing: libtermkey-dev 0.22-2
- ubuntu resolute: libtermkey-dev 0.22-2build1 Β· MIT
- ubuntu stonking: libtermkey-dev 0.22-3 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms