feat: opt-in Windows layout-aware shortcut chords - #269
Conversation
netniV
left a comment
There was a problem hiding this comment.
This feels like overkill. If the unity engine is capable of working both ways, we should be simply following what the game currently does. If we should override that, it is surely as simple as updating which mode it's operating in?
Additionally, we are resolving shortcuts during a keyframe in the key functions adding overhead.
Keyboard layouts change by nationality in more ways than just the alphabetic keys.
|
Ooo, I'll dig into this—thanks for the pointer! You're right, I should keep it slimmer, as always 😄 This already uses Unity's FindKeyOnCurrentKeyboardLayout to bridge layout-aware letters into our existing KeyCode polling, so configured Z follows the active layout. But the docs point to a cleaner change-notification approach that could move the layout checks out of the shortcut-query path. I'll investigate that, along with whether there's a simpler mode-setting option available to us. A–Z was deliberately the first slice, but fair point that layouts differ beyond letters too. I'll keep that distinction explicit while slimming this down. |
3b229c6 to
e8a4883
Compare
Configured punctuation now follows the active Windows keyboard layout, including the Shift needed to type it. For example,
/uses Shift+7 on German andCTRL-'uses Ctrl+Shift+#. Letters follow the active layout too. Physical mode remains the default.Restart once after changing the setting. Subsequent layout changes apply live. Hints and generated shortcut values retain the configured TOML text.
Implementation
German experimental shortcuts
Alliance Help and Armada retain upstream's
enable_experimental = truerequirement. The default HelpSHIFT-'shadows default ArmadaCTRL-'on German because apostrophe already requires Shift and existing modified shortcuts accept extra modifiers. Use this tested configuration in the existing sections:On a German keyboard, Armada is Ctrl+Shift+#, using the # key beside Enter. This documents the overlap without changing upstream shortcut defaults or modifier priority.
Validation
2915f4f; final heade8a4883.git diff --checkpasses. Remote CI is tracked separately.See layout behavior and configuration.