Sic transit gloria keycodi

Peter Hutterer peter.hutterer at
Tue Aug 24 15:31:38 PDT 2010

On Tue, Aug 24, 2010 at 08:38:33PM +0200, Andre Majorel wrote:
> It was apparently decided that evdev should have different
> keycodes than the usual. I for one welcome our new keycodes, the
> old ones weren't any good anyway.
> Now I need a way to query the X server for which keycodes mean
> what, or at least whether it's the traditional set or the evdev
> set.
> Is XGetKeyboardMapping() the way to do that ? Its removal is not
> in the plans, is it ?

In X, a keycode has no meaning other than being an index into the keysym
table. Which keycodes are used doesn't matter, XGetKeyboardMapping() is the
core protocol approach to obtaining the keysyms (which are what really
matters), or you just use XKB which is a tad more complex but more flexible

More information about the xorg mailing list