Skip to content

Continuous keyboard map scrolling - #133

Open
torradmin wants to merge 3 commits into
OpenTS-Developers:mainfrom
torradmin:fix/keyboard-map-scroll
Open

Continuous keyboard map scrolling#133
torradmin wants to merge 3 commits into
OpenTS-Developers:mainfrom
torradmin:fix/keyboard-map-scroll

Conversation

@torradmin

@torradmin torradmin commented Sep 5, 2026

Copy link
Copy Markdown

Summary

Binding "Scroll East/West/North/South" to a key now scrolls the map continuously
while the key is held, matching edge scrolling and mouse-drag scrolling. Before,
each press moved the map a single fixed step, because Windows key-repeat events
never reach the game's keyboard buffer — repeating the scroll required releasing
and pressing the key again. Held keyboard scroll ramps up to the same top speed
as edge scrolling and honors the "Scroll speed" option.

Behavior classification

  • Keyboard scroll: fixed — the four scroll commands are documented and bound
    by default but were effectively inert for sustained scrolling; this makes them
    work as a modder/player would expect from an edge-scroll-equivalent command.

No compatibility boundary (saves, replays, network, data formats) is touched;
this is local input handling only.

Documentation

Manual change records added:

  • manual/changes/keyboard-scroll-continuous.md
  • manual/changes/keyboard-scroll-diagonals-and-modifiers.md

Validation

  • Verified via manual testing that keyboard scrolling now works at a similar speed to edge scrolling and respects the scroll speed selected.

@tomsons26 tomsons26 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gonna block this for now as we need to look into how RA2 handles modifiers and repeats.
It probably shows a more intended way to handle this.

@ZivDero

ZivDero commented Sep 5, 2026

Copy link
Copy Markdown
Member

Gonna block this for now as we need to look into how RA2 handles modifiers and repeats. It probably shows a more intended way to handle this.

Yeah IIRC RA2 adds the key input with modifiers as Execute() argument, should look into it. This PR seems to be a bit overreaching.

… "Scroll East/West/North/South" instead of them basically being useless keybinds. Scroll speed with keyboard is similar to edge scrolling and takes into account the "Scroll speed" slider in options.

(cherry picked from commit 6956eff5aec6044bcd3f93383e182d13f73527ac)
(cherry picked from commit e5f1656)
@torradmin
torradmin force-pushed the fix/keyboard-map-scroll branch from b908a40 to eeb0dbf Compare September 6, 2026 08:42
@torradmin torradmin changed the title Continuous keyboard map scrolling and options-dialog Escape fixes Continuous keyboard map scrolling Sep 6, 2026
@torradmin

Copy link
Copy Markdown
Author

Gonna block this for now as we need to look into how RA2 handles modifiers and repeats. It probably shows a more intended way to handle this.

Not sure where to find the RA2 source code? I looked at OpenRA and made some fixes based on that for checking modifier keys.

@torradmin

Copy link
Copy Markdown
Author

Gonna block this for now as we need to look into how RA2 handles modifiers and repeats. It probably shows a more intended way to handle this.

Yeah IIRC RA2 adds the key input with modifiers as Execute() argument, should look into it. This PR seems to be a bit overreaching.

Removed the ESC/ALT+TAB fixes from this to be a bit less overreaching. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants