While xmodmap(1) handles all manner of translations for existing keysyms, the keysymdb is primarily concerned with adding new keysyms (it understands previously-defined keysyms as well). Keycodes are server-specific, numeric codes assigned to actual keys on a given keyboard type, while keysyms are server-independent, logical mappings of symbols to the actual keycodes.
The most common keysyms map directly to typical key legends ('A' or 'Shift'), but the keysyms discussed here often do not (as in the OSF keys above). The former type of keysym is built into your X server; the latter type does not exist for your system unless defined via the keysymdb.
As of X11R5, you may override the system keysymdb file, or supply your own, by setting the XKEYSYMDB variable to the path of the keysym file you wish to use. A common system location is /usr/local/lib/X11/XKeyymDB . A good user path is $USER/.xkeysymdb .
The keysymdb file is formatted as a standard Xrm resource file: lines beginning with '!' are comments, lines beginning with '#' should be #include statements (standard X11R5 does not support other C preprocessor directives in Xrm files except through the xrdb command), and all other (non-blank) lines must be of the format
resource_name : value(whitespace is ignored) as in the example below.
! ~/.xkeysymdb ! #include </usr/lib/X11/XKeysymDB> ! ! Delete should be Backspace for ! Cavenewt Super-3 workstation keyboards ! !osfDelete !osfBackspace ! osfDelete :<Key> Backspace osfBackspace :<Key> Delete osfRight :<Key> Right SunProps :1005FF70The OSF virtual keysyms are an example of the sort of things the keysym database is for. The keysym database is not intended for more general translations, so complex mappings, such as Alt<Key>1 for Sun's L1 key are not possible. Use xmodmap for this.
Motif clients often require some subset of the OSF keysyms. The Motif window manager (mwm(1)) typcially handles translations for Motif clients. mwm loads the system bindings by default. If you use another window manager or prefer to override the defaults, use Motif's xmbind command.
Ctrl Shift <Key> OsfMenu: popup-menu(mainMenu) \n\ Ctrl Meta <Key> OsfMenu: popup-menu(tekMenu) \n\or in configuration files such as the portion of an .mwmrc file shown below.
Keys DefaultKeyBindings { Ctrl Shift <Key> OsfMenu root f.menu HostsMenu Ctrl Meta <Key> OsfMenu root f.menu RootMenu Ctrl Shift Meta <Key> OsfDelete root f.exec "/usr/local/adm/reboot" }
For further reading on keysyms in general, see the X(1) man page, and the chapter on "Setup Clients" in Volume 3 of O'Reilly's Guide to the X Window System. You can find more information on Motif bindings in the Motif VirtualBindings(3) man page.
Copyright 1993, 1994 Miles O'Neal, Austin, TX. All rights reserved. Miles O'Neal <roadkills.r.us@XYZZY.gmail.com> [remove the "XYZZY." to make things work!] c/o RNN / 1705 Oak Forest Dr / Round Rock, TX / 78681-1514