Le jeudi 23 juin 2005 à 06:28 +0200, Rémy Saissy a écrit : > ok, look at the picture, the is the 0x49 which is F7 and > XF86AudioPause which is F7 too. First bound gave me XF86AudioPrevious, > second one XF86AudioStop... I tried it on a fresh installed system and > on an older one.
Hum i have been through X symbols. XF86AudioStop and such are only defined in the "inet" symbols file. This one defines special keys (named after firsts internet keyboards) for specific keyboard layout . Like ltcd for Logitech keyboards. You might have to find out if your keyboard is supported in gnome-keyboard-properties -> layout or the hard way : /etc/X11/xkb/rules/xfree86 , inetkbds variable list all the supported "inet" keyboards. (gnome uses /etc/X11/xkb/rules/xfree86.xml though the previous one is easier for humans to read). The available keys for each keyboards are listed in : /etc/X11/xkb/symbols/inet . Mine only support XF86WWW, XF86Search and XF86Search for example. If i want to map "Pause" in gnome to f7 , "F7" is the proper key name ('symbol'). Though if you want the other way round. That F7 fires up an XF86AudioStop events that even non gnome applications can understand, you would have to plays with the symbol file. For example creating your own "inet" keyboard: //my keyboard partial alphanumeric_keys xkb_symbols "my_keyboard" { name[Group1]= "My keyboard"; key <###> { [ XF86AudioPlay, XF86AudioPause ] }; }; replacing ### by the X internal key name. To find out which is the key name for F7 : $ grep F7 /etc/X11/xkb/symbols/* for my keyboard (french ) there is no mapping defined so it fails back to the us : /etc/X11/xkb/symbols/us: key <FK07> { [ F7 ] }; Thus : key <FK07> { [ XF86AudioPlay, XF86AudioPause ] }; then add "my_keyboard" to the inetkbds variable in /etc/X11/xkb/rules/xfree86 . And to /etc/X11/xkb/rules/xfree86.xml (copying from say ltcd example) if you want it to shows up in your gnome-keyboard-properties keyboard layout list . Confusing isn't it ? It all depends on what you are trying to achieve. Map a key to "Pause" in gnome keyboard properties or make F7 fires up an XF86AudioStop X event ... Regards Alban