[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Keyboard fun



Antony Gelberg wrote:

Two things:

1. My pound sign is a hash in X.  Works fine in the console.

From XF86Config-4:
Section "InputDevice"
       Identifier      "Generic Keyboard"
       Driver          "keyboard"
       Option          "CoreKeyboard"
       Option          "XkbRules"      "xfree86"
       Option          "XkbModel"      "logicordless"
       Option          "XkbLayout"     "gb"
EndSection

2. I have a Logitech cordless keyboard.  I'd like to assign some of the
"special" keys in Sawfish. When I use xev, I get events generated e.g.
KeyPress event, serial 27, synthetic NO, window 0x2400001,
   root 0x40, subw 0x2400002, time 673540, (18,21), root:(63,139),
   state 0x0, keycode 162 (keysym 0x0, NoSymbol), same_screen YES,
   XLookupString gives 0 bytes:  ""

KeyRelease event, serial 27, synthetic NO, window 0x2400001,
   root 0x40, subw 0x2400002, time 673733, (18,21), root:(63,139),
   state 0x0, keycode 162 (keysym 0x0, NoSymbol), same_screen YES,
   XLookupString gives 0 bytes:  ""

KeyPress event, serial 27, synthetic NO, window 0x2400001,
   root 0x40, subw 0x2400002, time 674085, (18,21), root:(63,139),
   state 0x0, keycode 164 (keysym 0x0, NoSymbol), same_screen YES,
   XLookupString gives 0 bytes:  ""

KeyRelease event, serial 27, synthetic NO, window 0x2400001,
   root 0x40, subw 0x2400002, time 674259, (18,21), root:(63,139),
   state 0x0, keycode 164 (keysym 0x0, NoSymbol), same_screen YES,
   XLookupString gives 0 bytes:  ""

But when I go into gnomecc to configure the shortcuts, and click "grab",
it doesn't respond when I press the key.

If anyone can shed any light I'd be very grateful.

Antony

In your home directory create a file called .Xmodmap. My looks like:
keycode 115 = F15
keycode 178 = F16
keycode 236 = F17

map your keycodes (162, 164 etc) to spare function keys, then run xmodmap ~/.Xmodmap.
Sawfish will now grab them as F15 etc

To make sure this file is read everytime you log into Gnome, in the file /etc/X11/Xsession.options, put the line:
allow-user-modmap

This works for me.

HTH

Bec









Reply to: