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

Re: [Xen-devel] [PATCH] Paravirt framebuffer backend tools [2/5]


On Sat, 2006-10-07 at 18:48 +0200, Markus Armbruster wrote:

> The backend gets keys in an encoding that depends on the software used
> to access the keyboard:
> * with SDL, struct SDL_keysym (consists of scancode, SDL keysym,
> current modifiers and optionally Unicode translation),
> * with LibVNCServer: rfbKeySym (which is just an X11 keysym).
> The frontend needs to stuff Linux keycodes into the input layer.
> Our job is to translate from frontend keysyms to Linux keycodes, and
> the question is to find out how and where.

Bear in mind that it may simply not be possible.  :-(

An example is my UK keyboard connecting to a guest with a US keymap.
For me, "#" is a key on its own (with "~" as the shift-modified key.)
When I type "#", with no modifier pressed, there is simply no way to
translate that to a single keycode on a US keymap and get the "#" ksym
out --- on a US keyboard, "#" requires shift to be held down.

The only way you'll get such a keypress through is by faking modifiers
on the fly.


Xen-devel mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.