[Bug 1181] New: - Keyboard translation broken: uses raw keycodes

wine-bugs at winehq.com wine-bugs at winehq.com
Fri Dec 6 07:30:47 CST 2002


http://bugs.winehq.com/show_bug.cgi?id=1181

           Summary: Keyboard translation broken: uses raw keycodes
           Product: Wine
           Version: CVS
          Platform: PC
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: major
          Priority: P2
         Component: wine-x11driver
        AssignedTo: wine-bugs at winehq.com
        ReportedBy: peter at cendio.se


The X11 keyboard driver (dlls/x11drv/keyboard.c) uses raw X11 keycodes. 
This is wrong; keycodes are Xserver and hardware dependent. Applications 
should never use the keycodes. 

One example when this is a problem is when using VNC, since Xvnc does not 
use the same keycodes as most XFree86 servers. This has led to that Wine 
has a special keymap for this special Xvnc server. But this keymap only 
supports the US keyboard layout. Basically, to support all layouts (x) on 
all servers (y), Wine needs to have x*y keymaps. This is just not feasible. 

And even if it was, things would go wrong: Xvnc allocates keycodes 
dynamically, which is totally "legal". This means that "aring" can have 
different keycodes different times, depending on in which order the user 
has pressed international keys. 

rdesktop (www.rdesktop.org) suffered from exactly the same problem. I have 
written a new keyboard translation implementation which uses Keysyms 
instead. Maybe Wine can re-use parts of this work.

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://bugs.winehq.com/show_bug.cgi?id=1181>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.



More information about the wine-bugs mailing list