XStringToKeysym, XKeysymToString, XKeycodeToKeysym, XKeysymToKeycode, XConvertCase - convert keysyms


KeySym XStringToKeysym(char *string); char *XKeysymToString(KeySym keysym); KeySym XKeycodeToKeysym(Display *display, KeyCode keycode, int index); KeyCode XKeysymToKeycode(Display *display, KeySym keysym); void XConvertCase(KeySym keysym, KeySym *lower_return, KeySym *upper_return);


display 1i Specifies the connection to the X server.

index 1i Specifies the element of KeyCode vector.

keycode 1i Specifies the KeyCode.

keysym 1i Specifies the KeySym that is to be \*(Fn.

lower_return 1i Returns the lowercase form of keysym, or keysym.

string 1i Specifies the name of the KeySym that is to be converted.

upper_return 1i Returns the uppercase form of keysym, or keysym.


Standard KeySym names are obtained from .hN X11/keysymdef.h by removing the XK_ prefix from each name. KeySyms that are not part of the Xlib standard also may be obtained with this function. The set of KeySyms that are available in this manner and the mechanisms by which Xlib obtains them is implementation-dependent.

If the KeySym name is not in the Host Portable Character Encoding, the result is implementation-dependent. If the specified string does not match a valid KeySym, .ZN XStringToKeysym returns .ZN NoSymbol .

The returned string is in a static area and must not be modified. The returned string is in the Host Portable Character Encoding. If the specified KeySym is not defined, .ZN XKeysymToString returns a NULL.

The .ZN XKeycodeToKeysym function uses internal Xlib tables and returns the KeySym defined for the specified KeyCode and the element of the KeyCode vector. If no symbol is defined, .ZN XKeycodeToKeysym returns .ZN NoSymbol . .ZN XKeycodeToKeysym predates the XKB extension. If you want to lookup a KeySym while using XKB you have to use .ZN XkbKeycodeToKeysym .

If the specified KeySym is not defined for any KeyCode, .ZN XKeysymToKeycode returns zero.

The .ZN XConvertCase function returns the uppercase and lowercase forms of the specified Keysym, if the KeySym is subject to case conversion; otherwise, the specified KeySym is returned to both lower_return and upper_return. Support for conversion of other than Latin and Cyrillic KeySyms is implementation-dependent.