This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
Home Products Support Community News


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

Steven Smith wrote:
First: I now agree with you that scancodes are a better choice than
keysyms, and that I was wrong initially.
The problem with scancodes is that you cannot always get scancodes from the viewer. You can get scancodes from SDL but you can only get keysyms from VNC. We would have to map VNC keysyms (which are just Xk keysyms) to scancodes?
Ian just pointed out that there's some code in rdesktop to do just
that.  xkeymap.c contains stuff to pull the keymap out of the X
server, parse it up, and then do keysym->scancode translation.  Of
course, choosing a suitable keymap isn't entirely trivial, since the
server can't see what keymap the client's using.

There is also code in QEMU that does the translation. In fact, the QEMU code is based on the rdesktop tables :-)

Since the QEMU tables are already installed (in /usr/share/qemu/keymaps) I suppose it's best to use those.


Anthony Liguori


Xen-devel mailing list

<Prev in Thread] Current Thread [Next in Thread>