[wplug] Talking about keystroke bindings

Jonathan S Billings billings at negate.org
Fri Dec 15 09:42:21 EST 2000


On Fri, 15 Dec 2000, Rafael E. Herrera wrote:

> Hi,
> 
> Thinking about the recent alt-ctrl-del discussion it occurred to me that
> I'd like to use the extra keys on my keyboard. I've three extra keys in
> my HP keyboard (labeled Internet, Suspend, Information). Does anybody
> know how to make a program run when I push these keys? or some program
> out there that lets you use them?

Some of these keys require special software (i.e. windows) but I've seen
ones that generated keycodes.  You can check this out by using the program
xev in X.  I'm not sure about what you can use on the console.  xev will
give you a pretty detailed description of the xevents going on.  for
example, I get this when I press the space key:

KeyPress event, serial 24, synthetic NO, window 0x6800001,
    root 0x26, subw 0x0, time 1933252039, (66,147), root:(753,710),
    state 0x10, keycode 65 (keysym 0x20, space), same_screen YES,
    XLookupString gives 1 characters:  " "

KeyRelease event, serial 24, synthetic NO, window 0x6800001,
    root 0x26, subw 0x0, time 1933252125, (66,147), root:(753,710),
    state 0x10, keycode 65 (keysym 0x20, space), same_screen YES,
    XLookupString gives 1 characters:  " "

You can see that it's keycode 65.  If you can get a keycode, and use
xmodmap to turn it into some symbol.  Then do with it as you will, make it
a button click, maybe make it so your wm recognizes it and starts
netscape.

Jonathan Billings




More information about the wplug mailing list