keymaps and scancodes

Questions about Wine on Linux
Locked
rekuli
Level 2
Level 2
Posts: 26
Joined: Tue Dec 22, 2009 10:12 pm

keymaps and scancodes

Post by rekuli »

Sorry if I re-ask a question, but I couldn't find a satisfying answer yet to the following problem:

I installed wine on a UTF-8 Linux system, and everything works fine (running Wine 1.3.something, currently). But when I installed some games where you can use ^(~ on german keyboards) to open a console, nothing happens. Even when I ported some windows games over - installed in wine, deleted gamedir, copied gamedir from old windows installation - it does not work. And it does not matter if run wine as X11 wm or inside another wm.
Do I need to tell windows to use scancodes instead of the host OS's keymappings? How do I do that?

Thanks for any idea.
rekuli
Level 2
Level 2
Posts: 26
Joined: Tue Dec 22, 2009 10:12 pm

Post by rekuli »

Just to be correct: wine version is 1.3.36, and everything else works like it did in a win98 or winxp system.
I just tried (again) disabling any input systems on system-wide level and using the classic nodeadkeys map in xorg.conf, no change.
btw: I confused something -- ~ is the key on gb/us keyboards, on german ones it is ^ (the one left of 1). And it still doesn't work to call up the console in the games where it ought to to so.
rekuli
Level 2
Level 2
Posts: 26
Joined: Tue Dec 22, 2009 10:12 pm

Post by rekuli »

. . . does *NOBODY* except me have this problem and/or solved it? Or did I just choose the wrong topic title?

Again: If I want Wine to use IBM-PC keyboard *SCANCODES* instead of GUI Keymaps, how do I do that? Do I need to edit the Registry? Where to put What which way?

Please, help, anybody.
lahmbi5678
Level 7
Level 7
Posts: 823
Joined: Thu Aug 27, 2009 6:23 am

Post by lahmbi5678 »

Hi,

I'm not a wine developer, but recently there has been a fix for a keyboard issue, see http://www.winehq.org/pipermail/wine-pa ... 14989.html Did you try some (all) other keys, maybe you could find the "right" one?

The patch mentioned should be in next wine release (which would be due this Friday). If your issue still wouldn't be fixed, you might file a bug.
lahmbi5678
Level 7
Level 7
Posts: 823
Joined: Thu Aug 27, 2009 6:23 am

Post by lahmbi5678 »

Hi,

there's a bug report probably about the same issue, http://bugs.winehq.org/show_bug.cgi?id=30984 ,if the ^-key shouldn't work for you with wine 1.5.7, you may add your experience there.
rekuli
Level 2
Level 2
Posts: 26
Joined: Tue Dec 22, 2009 10:12 pm

Post by rekuli »

thank you so far, lahmbi. But those refs are basically just other calls for kelp with the same issue which might be resolved with fixes in 1.5.x.
It is not just Trine and Skyrim, bit Morrowind, Oblivion, Quake, and all other games that use ~ (or ^ on german keyboards) for the console were this does not work. Not really of life-saving importance, but an annoying nuisance that drives me towards running a triple boot with XP and 98 again (virtual machine is too slow).

But there is still no information about if and how I can use pc-scancodes instead of keymaps, or if it is possible at all without re-programming parts of wine itself.
lahmbi5678
Level 7
Level 7
Posts: 823
Joined: Thu Aug 27, 2009 6:23 am

Post by lahmbi5678 »

Hi,

I'm not sure what you mean with scancodes, wine is different from DOS/Windows x86 assembly, it gets its "scancodes" from Xlib. The issue has to be fixed in wine. Fortunately two of the guys contributing to the bug report are official wine developers (Ken Thomasses, Vincent Povirk, Codeweavers). The just won't have be used to german settings/keyboards, so you could really be helpful by providing the required logs by commands like

xmodmap-pk

WINEDEBUG=+key,+keyboard,+event wine yourapp.exe

In some games it should be possible to change keyboard settings to use a different key to open the game's console, alternatively you could try all possible keys on your keyboard, maybe there's another way to "reach" the right key, but I doubt, that it would work. Would it help if you changed your keyboard layout to US?
rekuli
Level 2
Level 2
Posts: 26
Joined: Tue Dec 22, 2009 10:12 pm

Post by rekuli »

Hi lahmbi,

There's no difference whether I use german, us, gb, chinese, arabic, or any other keymap. Current setup is german w/deadkeys UTF-8 system-wide, and xorg.conf uses pc105,de,deadkeys. Via gnome kbd switcher I usually override the actual keymap, but I turned this off, as well as trying "C"/Latin-1 as X11 default language/keymapping. No change, whatsoever.

Concerning scancodes: curious that Wine doesn't have a hard-coded fallback using the PC-AT BIOS keyboard scancodes (which I mean).

XF86Explorer reports "No Symbol" regarding the ^ key on german keymap (using WINEDEBUG like you suggested). And regarding the ~ key in US-based keymaps.
lahmbi5678
Level 7
Level 7
Posts: 823
Joined: Thu Aug 27, 2009 6:23 am

Post by lahmbi5678 »

Hi,

I'm not really an expert. There's a simple tool called "xev" (type it in a terminal), which shows X events, you could try it just to see, what X events are triggered when pressing the said key. Again, please report your findings to the guy in the bug report, Ken Thomasses.
rekuli
Level 2
Level 2
Posts: 26
Joined: Tue Dec 22, 2009 10:12 pm

Post by rekuli »

Yep, I am gathering all info right now and will report to him :-).

Thanks nonetheless for your support, lahmbi. Someday there'll be some beer on your doorstep ;-).
Locked