https://bugs.winehq.org/show_bug.cgi?id=53057
Bug ID: 53057 Summary: Wine 7.9 and converts ~ key to "vkey 0xDE scan 63" instead of "vkey 0xDC scan 29" preventing it from functioning properly. Product: Wine Version: 7.8 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: -unknown Assignee: wine-bugs@winehq.org Reporter: winehq@pp.dyndns.biz Distribution: ---
Created attachment 72460 --> https://bugs.winehq.org/attachment.cgi?id=72460 Short +key trace from 7.7 and 7.8
The tilde key (~) is converted differently in Wine 7.8 than in Wine 7.7. The problem persists also in Wine 7.9. In my case it's used to bring down a text console in Star Trek Online and that stopped working in 7.8. I've attached a short +key trace from 7.7 and 7.8 just to show the difference between the latest working version and the first non-working version.
If it makes a difference, I'm not actually on an American keyboard. It's a qwerty keyboard with Swedish/Nordic layout so that key produces a § character for me. But it's the same scancode and the key is used as the standard console key in several games.
https://bugs.winehq.org/show_bug.cgi?id=53057
Morgan Wesström winehq@pp.dyndns.biz changed:
What |Removed |Added ---------------------------------------------------------------------------- Summary|Wine 7.9 and converts ~ key |Wine 7.8 converts ~ key to |to "vkey 0xDE scan 63" |"vkey 0xDE scan 63" instead |instead of "vkey 0xDC scan |of "vkey 0xDC scan 29" |29" preventing it from |preventing it from |functioning properly. |functioning properly.
https://bugs.winehq.org/show_bug.cgi?id=53057
Fabian Maurer dark.shadow4@web.de changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |dark.shadow4@web.de Keywords| |regression
--- Comment #1 from Fabian Maurer dark.shadow4@web.de --- Can you do a regression test to find out which commit broke it? See https://wiki.winehq.org/Regression_Testing
https://bugs.winehq.org/show_bug.cgi?id=53057
--- Comment #2 from Rafał Mużyło galtgendo@o2.pl --- It seems that there weren't any changes in that part of the code lately.
Were there any earlier differences in that log ? Specifically, in the part that's populating keyc2vkey.
https://bugs.winehq.org/show_bug.cgi?id=53057
Gijs Vermeulen gijsvrm@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Summary|Wine 7.8 converts ~ key to |Tilde key is converted to |"vkey 0xDE scan 63" instead |"vkey 0xDE scan 63" instead |of "vkey 0xDC scan 29" |of "vkey 0xDC scan 29" |preventing it from | |functioning properly. |
https://bugs.winehq.org/show_bug.cgi?id=53057
--- Comment #3 from Morgan Wesström winehq@pp.dyndns.biz --- (In reply to Fabian Maurer from comment #1)
Can you do a regression test to find out which commit broke it? See https://wiki.winehq.org/Regression_Testing
I feared that you would ask that and was hoping someone would recognize the affected code paths. ;) I'm using Gentoo and I'll see if I can figure out how to use its package system to build Wine from a local copy of the git repository. For now I'm fine with 7.7 and perhaps someone else runs into this before I master the regression test. :)
https://bugs.winehq.org/show_bug.cgi?id=53057
--- Comment #4 from Morgan Wesström winehq@pp.dyndns.biz --- (In reply to Rafał Mużyło from comment #2)
It seems that there weren't any changes in that part of the code lately.
Were there any earlier differences in that log ? Specifically, in the part that's populating keyc2vkey.
Is there a way to get a timestamp in the trace log? There is a lot of output in it while the game loads but I'm reasonably sure that the log snippets I attached are from the point where I first pressed the tilde key, but timestamps would make it a lot easier to confirm.
https://bugs.winehq.org/show_bug.cgi?id=53057
--- Comment #5 from Rafał Mużyło galtgendo@o2.pl ---
Is there a way to get a timestamp in the trace log?
Exactly that, 'timestamp' channel.
But that doesn't matter, the initialization of keyc2vkey likely happened long before, during X11DRV_InitKeyboard.
Also, see git-3.eclass - likely EGIT_COMMIT and EGIT_CHECKOUT_DIR are a part of the answer for 9999 ebuild though chances are it won't be all that straightforward/convenient (live ebuilds rarely are).
https://bugs.winehq.org/show_bug.cgi?id=53057
--- Comment #6 from Morgan Wesström winehq@pp.dyndns.biz --- (In reply to Rafał Mużyło from comment #5)
Is there a way to get a timestamp in the trace log?
Exactly that, 'timestamp' channel.
Thank you, I feel stupid now. :)
Also, see git-3.eclass - likely EGIT_COMMIT and EGIT_CHECKOUT_DIR are a part of the answer for 9999 ebuild though chances are it won't be all that straightforward/convenient (live ebuilds rarely are).
I stumbled over EGIT_COMMIT too in my investigation so if it comes to it, I'll make a local copy of the 9999-ebuild and try that.
I did however make a faulty assumption in my first assessment of this bug and I apologize for that. I'm normally using wine-staging and this bug hit me in wine-staging 7.8. To rule out the staging patchset I installed wine-vanilla 7.8 and confirmed the bug was there too, then making the assumption the bug appeared between 7.7. and 7.8. During further investigation today I realized the bug is there in even earlier versions of wine-vanilla but not in wine-staging. I'm currently compiling wine-vanilla 7.3 but it takes about an hour per version on my old machine so it may take a while until I figure out exactly which version introduced the bug. Interesting though that the staging patchset reversed the bug up until 7.7.
I will updated this report as soon as I've found the first regular version where the bug appears. Hopefully that can give a hint to what commit is responsible but I will give the regression testing a shot if necessary.
https://bugs.winehq.org/show_bug.cgi?id=53057
--- Comment #7 from Rafał Mużyło galtgendo@o2.pl --- ... Let's just hope this won't end up a case of the bug being in vanilla effectively forever and only actual change was a staging patch being turned ineffective.
... On that note, did you check if staging didn't simply drop a patch due to it becoming incompatible with some recent changes ?
https://bugs.winehq.org/show_bug.cgi?id=53057
--- Comment #8 from Rafał Mużyło galtgendo@o2.pl --- In fact, note this staging commit: https://github.com/wine-staging/wine-staging/commit/699309db0f2e54881409cf2a....
The disabled patchset sounds suspiciously like your problem.
https://bugs.winehq.org/show_bug.cgi?id=53057
--- Comment #9 from Morgan Wesström winehq@pp.dyndns.biz --- (In reply to Rafał Mużyło from comment #7)
... Let's just hope this won't end up a case of the bug being in vanilla effectively forever and only actual change was a staging patch being turned ineffective.
I'm afraid it actually looks that way. I've now reached 6.22 (also tested stable 6.0.2) and I can't make the console key work in any vanilla version. After turning to Google I found several references from other Linux/Wine users with the same problem in various games which utilize the same console key mechanics. The workaround was to switch to US keyboard layout. I tried it and all the wine versions, that I had still left on my system, suddenly had a working console with the tilde key.
So to summarize, it seems this mechanics only works with US keyboard layout on wine-vanilla. It works with US and Swedish keyboard layouts (and presumably others too) in wine-staging up to and including version 7.7. From 7.8 onwards, the bahaviour is non-functional and identical to wine-vanilla. Needless to say, when the game is run on native Windows, keyboard layout doesn't matter. The console key always works.
After this realization I did indeed look at the staging commits but didn't find the particular one you linked. I thank you for that.
So it does look that this was indeed functionality added by the staging patchset and my bug report should probably be considered invalid and instead be labeled a missing feature request. For now I can live with the workaround and switch to US keyboard layout when needed. I will have a look at the patch you linked and as long as it doesn't need tons of maintenance, I can add it as a local patch when I compile wine.
https://bugs.winehq.org/show_bug.cgi?id=53057
--- Comment #10 from Morgan Wesström winehq@pp.dyndns.biz --- (In reply to Rafał Mużyło from comment #8)
In fact, note this staging commit: https://github.com/wine-staging/wine-staging/commit/ 699309db0f2e54881409cf2a05d4ec6628b171e9.
The disabled patchset sounds suspiciously like your problem.
Yeah, it's definitely that one. Now that I know the patch name I found multiple references to it and it goes all they way back to 2012. It was removed due to being incompatible with the ongoing PE conversion.
https://github.com/wine-staging/wine-staging/blob/master/patches/winex11-key...
Interestingly it was included in Proton back in 2019. I expect a major outcry from the player base when they sync their fork to 7.8. But hopefully some clever developer might find a way to re-implement it. I strongly suggest this should be a part of wine-vanilla though.
https://github.com/ValveSoftware/Proton/issues/2477
https://bugs.winehq.org/show_bug.cgi?id=53057
Zeb Figura z.figura12@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords|regression | Product|Wine |Wine-staging Component|-unknown |-unknown CC| |leslie_alistair@hotmail.com | |, z.figura12@gmail.com
--- Comment #11 from Zeb Figura z.figura12@gmail.com --- The diagnosis of this being a wine-staging "regression" was never verified, but I'm going to assume it was correct.
The relevant wine-staging patch has been replaced with winex11-Fixed-scancodes. If possible please retest with current wine-staging.
https://bugs.winehq.org/show_bug.cgi?id=53057
--- Comment #12 from Morgan Wesström winehq@pp.dyndns.biz --- Tested with wine-staging 9.0-rc4 and the tilde button now works again even with my Swedish keyboard layout. Thank you! :-)
https://bugs.winehq.org/show_bug.cgi?id=53057
Zeb Figura z.figura12@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|UNCONFIRMED |RESOLVED
--- Comment #13 from Zeb Figura z.figura12@gmail.com --- (In reply to Morgan Wesström from comment #12)
Tested with wine-staging 9.0-rc4 and the tilde button now works again even with my Swedish keyboard layout. Thank you! :-)
Marking fixed then; thanks for testing.
https://bugs.winehq.org/show_bug.cgi?id=53057
Alistair Leslie-Hughes leslie_alistair@hotmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #14 from Alistair Leslie-Hughes leslie_alistair@hotmail.com --- Closing Fixed wine-staging bug.