Rikki,

    As far as I know, wine keyboard.c uses XFree86 Keymap table to compare your key definitions with their internal geometry. After that, it maps every scan code to a virtual key. The virtual key  is mapped back to a scan code and to an unicode symbol by ToUnicode function. During this proccess, it uses part of the original xfree mapping.
    On the original ToUnicode function, it uses the function XLookupString (a Xlib function) to map scan code->symbol. This function is capable to work with latin characters, but it doesn't implement dead keys translation on the current XFree86 implementations. In the past, there was some Xlib hacking that changes this behavor (X11 R5 implementations). The new standard (X11 R6) creates the xkb extensions, that provides new functions to treat locale imput data (XmbLookupString, Xutf8LookupString and XwcLookupString). What it does is to use XFree86 locale settings to make this map.
    The dead key treatment is defined on /usr/X11R6/lib/X11/locale.
    The geometry of their keyboards, used by xkb, are on /usr/X11R6/lib/X11/xkb (RedHat) or /etc/X11/xkb (Mandrake). The file symbols/is, for example, contains some icelandic definitions.
    From your answer, I would try to fix the XFree86 keyboard mapping on symbols/is. I guess that this will solve both XFree and Wine (patched).


Richard Allen wrote:
On Wed, Jan 08, 2003 at 12:55:15PM -0200, Mauro Carvalho Chehab wrote:
  
 Rikki,

   Please try to apply the following patch against the new CVS version 
(on /dlls/x11drv directory). This patch will allow keyboard.c to use 
your locale setting by the usage of xkb extension on X11R6. Please 
notice that this requires that you *don't have* xkbdisable on your 
XF86Config file (or XF86Config-4).
    

I applied the patch and did a recompile on todays CVS.   I see a change, but
it does not fix things for Icelandic.   My mute key is:

[ra@morticia ra]$ xmodmap -pke | grep dead_acute
keycode  48 = dead_acute Adiaeresis dead_circumflex dead_caron

Its dead_acute I need to get working.   With your patch it still doesnt 
work, but pressing "alt and the mute key" (dead_circumflex) works.
So I can get characters like â ê û î :)

Btw, that key is incorrect from the XFree.org people.  That Adiaeresis is
not supposed to be there and causes wine to complain:

fixme:keyboard:X11DRV_KEYBOARD_DetectLayout Your keyboard layout was not found!
Using closest match instead (Icelandic keyboard layout) for scancode mapping.
Please define your layout in windows/x11drv/keyboard.c and submit them
to us for inclusion into future Wine releases.
See the Wine User Guide, chapter "Keyboard" for more information.


I enabled debugging and its that key thats causing the complaint.  All the
others are right.

So I added the Adiaeresis to the definition for the Icelandic keymap in 
keyboard.c and the complaint went away, but it's still not working :)