Commit Graph

11 Commits

Author SHA1 Message Date
6bb1de61ec Format hotkey tooltip when an alternate key-name is used
Some keys have multiple names that they may be identified by in config
files,
such as the Escape key which may be identified by either "Esc" or
"Escape", or
the number-pad keys which may be identified with a name in the form
"Num{xxx}"
(e.g. "NumMinus") or the alternate "Keypad {x}" (e.g. "Keypad -").

The alternate names were not being picked up and formatted correctly
when
displayed in tooltips. Now they are.


Accepted By: wraitii
Differential Revision: https://code.wildfiregames.com/D3358
This was SVN commit r24668.
2021-01-17 16:04:51 +00:00
a4852c4c01 Let players remap hotkeys in-game, fix default hotkeys being qwerty-specific.
- Provide a "Hotkey" screen to let players remap hotkeys in-game using a
convenient setup.
- Make all .cfg hotkeys refer to scancodes (i.e. position on the
keyboard), so that default hotkeys now translate correctly for AZERTY,
QWERTZ and other layouts.
- 'BackSpace' is now an alias for 'Delete', and works for killing units.
This fixes #1917, as macs don't have a proper delete key and would need
to use Fn+Del otherwise. This shifts "timewarp" to Shift+BackSpace.

Functionally, this switches hotkeys to scancodes, as that makes more
sense (they are combinations of key positions, not actual text output).
SDL includes are cleaned and key names are reused.

Fixes #2850, Fixes #2604, Refs #1810, Fixes #1917.

Follows work in 3d7784d2af.

Various diffs tested by: Angen, Stan, Freagarach
Comments by: Nescio
Differential Revision: https://code.wildfiregames.com/D2814
This was SVN commit r24215.
2020-11-19 09:27:26 +00:00
3d7784d2af Try to recognise unknown hotkey mappings using SDL2.
This improves our international keyboard until we completely rework the
hotkey system which seems to be quite legacy at this point.

Reviewed by Itms.
Differential Revision: https://code.wildfiregames.com/D303
This was SVN commit r19624.
2017-05-21 08:05:52 +00:00
30fa275f9d Fixed some keys not being recognized after a719696658. Refs #195.
This was SVN commit r15610.
2014-08-04 16:48:54 +00:00
a719696658 Support more mouse buttons. Fixes #195. Patch by 01d55 with some minor cleanup.
This was SVN commit r15609.
2014-08-04 01:06:36 +00:00
4a805fb05c Updates keys.txt with new keynames, refs #2043
This was SVN commit r13628.
2013-08-03 20:39:15 +00:00
10373892be Adds support for Apple command/meta hotkeys by grouping them with unified "Super" hotkey (not bothering to handle the distinction which is only relevant to Apple keyboards and SDL 1.2).
Adds Super+Q hotkey to close the game on OS X.

This was SVN commit r13195.
2013-02-24 21:42:21 +00:00
e43eb0c18b # Various hotkey fixes and cleanups.
Support ctrl for removing entities from selection.
Move big screenshot hotkey to shift+F2.
Increase mouse wheel rotation speed.
Fix HotkeyIsPressed when a more specific hotkey was matched instead.
Support multiple hotkeys with the same binding.
Use hotkeys instead of raw key events in GUI.
Delete some obsolete hotkey definitions.
Remove unused broken EntitySelection toggle method.

This was SVN commit r8546.
2010-11-07 20:42:52 +00:00
93c30810c8 Fix tests. Tidy up some old files.
This was SVN commit r7507.
2010-05-07 16:32:33 +00:00
b2f5a6cafc Clean up some SVN properties.
Remove empty unused cache directory.

This was SVN commit r7398.
2010-03-26 11:30:49 +00:00
MarkT
d8b5d3a78d Directory structure shuffle.
This was SVN commit r886.
2004-08-02 23:14:06 +00:00