Java Mailing List Archive

http://www.redhatconfig.com/

Home » Mandriva Cooker »

Re: [Cooker] How do I find what physical key corresponds to a
 given keycode

pcpa

2008-06-15

Replies: Find Java Web Hosting

Author LoginPost Reply
Quoting Pixel <pixel@(protected)>:

> Steve Morris <samorris@(protected):
>
>> I have issued the xmodmap -pk command to find the keycode mappings for the
>> generic 105 key and the Acer Laptop keyboard drivers, and both drivers have
>> keycode 106 = insert and keycode 107 = delete. On my Acer laptop the delete
>> key is physically next to the insert key but according to xev the delete key
>> is not keycode 107 it is 242. How do I find out what key actually is keycode
>> 107?
>
> keycode are given by the kernel to xorg.
>
> see getkeycodes for the scancode to keycode table

The X Server (input module handling the keyboard actually) translates
the values returned by the kernel, and the kernel usually doesn't apply
any translation table when reading raw input from the keyboard.
See /usr/share/X11/xkb/keycodes/xfree86 that is soon to be replaced by
only /usr/share/X11/xkb/keycodes/evdev

>> Also as a side issue, is it possible to assign a program to a
>> keyboard key as
>> can be done under Windows, eg: under Windows, via vendor supplied
>> software, it
>> is possible to assign IE to a keyboard key so that pressing that key
>> launches
>> IE, hence is it possible to do the same thing under Linux?
>
> it is possible, but it depends what desktop you use (kde, gnome...)

They have or should have some special keysyms.
See /usr/share/X11/xkb/symbols/inet and /usr/share/X11/XKeysymDB
for the XF86xxx values.

Disclaimer: I am not a xkb expert, so I suggest looking at those files,
and if you want to change behaviour, you may need to do some trial error,
and reload the configuration with setxkbmap, from a running X Server.
If you achieve the desirable configuration, but still requires changing
xkb configuration files, you should submit a bug report to upstream.

Paulo



©2008 redhatconfig.com - Jax Systems, LLC, U.S.A.