bugBattle for Wesnoth - Bugs: bug #18868, Hotkeys now go by qwerty layout,...

Show feedback again

bug #18868: Hotkeys now go by qwerty layout, and not what is set in Windows

Submitted by:  SigurdFireDragon <sigurdthedragon>
Submitted on:  Thu Oct 27 05:51:27 2011  
Category: BugSeverity: 1 - Wish
Priority: 1 - LaterItem Group: User Interface
Status: FixedPrivacy: Public
Assigned to: NoneOpen/Closed: Closed
Release: r51670Operating System: Win 7 x64

Add a New Comment (Rich MarkupRich Markup):

You are not logged in

Please log in, so followups can be emailed to you.


(Jump to the original submission Jump to the original submission)

Mon Nov 7 10:57:42 2016, comment #12:

Closing as requested.

Wedge009 <wedge009>
Project Member
Mon Sep 5 02:14:14 2016, comment #11:

The hotkey system in master is working fine now after the sdl2 merge and the new hotkey implementation.

This can be closed now.

SigurdFireDragon <sigurdfdragon>
Sat Jul 23 16:30:58 2016, comment #10:

marking as ready for test since sdl2 barnch was merged

Daniel <gfgtdf>
Project Member
Sun Dec 29 05:33:37 2013, comment #9:

This will be addressed with the the switch to sdl 2.0.

Fabian Müller <fendrin>
Project Member
Thu Dec 1 15:27:11 2011, comment #8:

see also bug #19084

Anonymissimus <anonymissimus>
Project Member
Sat Nov 5 08:01:44 2011, comment #7:

"Still I am not sure about the original bug.
I guess that one of the hotkey representations is broken for your setup,
independent from the gui problem and how the hotkeys are displayed to the user."

r51664 did end up fixing bug #15567, but the bug I experienced (#18868) suggests that anyone who uses windows with anything other than the qwerty keyboard (any other language really) will find that their hotkeys aren't moving to match the layout they selected.

Having looked at the code (this is a little complex for my current C++ skills), I'm getting the sense that there is no simple solution, Other than what I proposed in my previous post, plus some hack to fix #15565 and make ctrl+alt+m work on windows. (don't know if possible.)

If not one option would be using r51664, along with code added that used something other than SDL for key input only on Windows. (thought that would take time and might be a bad idea, I don't know)

SigurdFireDragon <sigurdthedragon>
Sat Nov 5 00:44:03 2011, comment #6:

Sigurd, it sounds like a good idea to do that.
Still I am not sure about the original bug.
I guess that one of the hotkey representations is broken for your setup,
independent from the gui problem and how the hotkeys are displayed to the user.

Fabian Müller <fendrin>
Project Member
Mon Oct 31 19:10:28 2011, comment #5:

fendrin, anonymissiums:

With the shift +'s not working right;

Given that: When changing a hotkey in the game, it enters "shift + c" as "C"
That the comments in ln 400 hotkeys.cpp agree that this is the desired behavior, also indicating a desire not to break old peferences.

The patch I would write would merely change what default hotkeys are created in the preferences file when an existing preferences file cannot be found. Specificaly replacing all occurances of "shift + char" with just the proper character, except the special ones like "space".

Thus, new installs with new preferences would automatically get the correct behavior on the hotkeys in question; and comptablity with old preferences be maintained, with the user able to change the key if need be.

If you agree with that, I'll go ahead and right up a patch to do that.

SigurdFireDragon <sigurdthedragon>
Fri Oct 28 16:30:37 2011, comment #4:

Tried purging the preferences, thnigs still are as in my last comment.

Checked with r51660, it is as you say.

The shift +'s not working right with a different keyboard layout are present in 1.9.9 and 1.8.6

SigurdFireDragon <sigurdthedragon>
Thu Oct 27 23:52:40 2011, comment #3:

Sigurd: maybe try deleting (renaming...) you preferences file (are the keys saved there ? probably)
The alt+ctrl parts are another bug: bug #15567
In any case, the stuff must've been present before fendrin's modifications.

Anonymissimus <anonymissimus>
Project Member
Thu Oct 27 18:26:50 2011, comment #2:

reverting r51664 was a parital fix

the x's(one letters), alt +'s, crtl +'s work now

the shift +'s are still remaining in the qwerty spots

the alt+ctrl+r & alt+ctrl+m are not working at all.

if ":" is listed as just that (without a shift in the [hotkey] tag), it works right, if it is listed as shift+; it does not work right.

SigurdFireDragon <sigurdthedragon>
Thu Oct 27 14:45:21 2011, comment #1:

Fix for bug #17323 reverted (r51664)

Since we have two cases how to handle hotkeys, one for simple ones like single key presses or modified ones with only shift involved and the more complicated ones, I would like to know if the more complicated ones like (ctrl+alt+w) respect the loyout remapping as well.

Fabian Müller <fendrin>
Project Member
Thu Oct 27 05:51:27 2011, original submission:

Previously, I could change the keyboard layout in Windows, and the hotkeys would be remapped as expected in Wesnoth. (I am using US-Dvorak in Windows)

Now, they are no longer remapped and instead remain in their qwerty keyboard layout positions.

SigurdFireDragon <sigurdthedragon>


(Note: upload size limit is set to 1024 kB, after insertion of the required escape characters.)

Attach File(s):

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by wedge009 (Posted a comment)
  • -unavailable- added by sigurdfdragon (Posted a comment)
  • -unavailable- added by gfgtdf (Posted a comment)
  • -unavailable- added by shadowmaster (Updated the item)
  • -unavailable- added by anonymissimus (Posted a comment)
  • -unavailable- added by fendrin (Posted a comment)
  • -unavailable- added by sigurdthedragon (Submitted the item)

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.


    Error: not logged in



    Follow 12 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Mon Nov 7 10:57:42 2016wedge009StatusReady For Test=>Fixed
    Sat Jul 23 16:30:58 2016gfgtdfStatusPostponed=>Ready For Test
    Thu Oct 22 19:25:20 2015fendrinAssigned tofendrin=>None
    Fri Jun 6 18:16:06 2014fendrinSeverity4 - Important=>1 - Wish
      Priority5 - Normal=>1 - Later
    Sun Dec 29 05:33:37 2013fendrinStatusNone=>Postponed
    Sun Jan 29 21:14:51 2012shadowmasterStatusPostponed=>None
    Sun Jan 15 23:02:49 2012fendrinStatusNeed Info=>Postponed
    Thu Jan 5 17:42:39 2012fendrinSeverity3 - Normal=>4 - Important
    Thu Oct 27 14:45:21 2011fendrinStatusNone=>Need Info
    Thu Oct 27 14:20:34 2011anonymissimusAssigned toNone=>fendrin
    Show feedback again

    Back to the top

    Powered by Savane 3.1-cleanup