Skip to content

fix: use synthetic mouse events for scrolling in apps#63

Merged
orhun merged 1 commit into
mainfrom
fix/scrolling-in-apps
May 17, 2026
Merged

fix: use synthetic mouse events for scrolling in apps#63
orhun merged 1 commit into
mainfrom
fix/scrolling-in-apps

Conversation

@orhun

@orhun orhun commented May 17, 2026

Copy link
Copy Markdown
Owner

This commit routes keyboard scroll actions through synthetic mouse wheel events
when the foreground application has mouse mode enabled.

Ratty's local scrollback is based on vt100::Screen::set_scrollback(...),
which works for scrollback Ratty actually owns. But apps like zellij already
manage their own scrolling behavior and respond correctly to
forwarded mouse wheel input.

Reusing that same path for keyboard scroll bindings makes Alt+Up/Down
behave consistently in those applications instead of relying on Ratty-local scrollback.

See #49

This commit routes keyboard scroll actions through synthetic mouse wheel events
when the foreground application has mouse mode enabled.

Ratty's local scrollback is based on `vt100::Screen::set_scrollback(...)`,
which works for scrollback Ratty actually owns. But apps like zellij already
manage their own scrolling behavior and respond correctly to
forwarded mouse wheel input.

Reusing that same path for keyboard scroll bindings makes Alt+Up/Down
behave consistently in those applications instead of relying on Ratty-local scrollback.
@orhun orhun merged commit 2b05b7d into main May 17, 2026
11 checks passed
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.

1 participant