fix(tui): restore wheel scroll on macOS in tuiapp_v2#361
Merged
Conversation
PR lsdefine#360 disabled Textual mouse support on darwin (run(mouse=False)) to keep terminal-native selection working. Side effect: ?1006 SGR mouse was never enabled, while macOS Terminal.app / iTerm2 default ?1007 (alternate scroll mode) translated wheel events into Up/Down keys — which then triggered the newly added input-history navigation. Re-enable mouse globally and explicitly disable ?1007 on mount so wheel events flow through the SGR channel without spawning duplicate arrow keys. Keyboard Up/Down history navigation is unaffected. The ?1007 disable is a no-op on Linux / Windows Terminal where it defaults off.
Merged
RocketLi
pushed a commit
to RocketLi/GenericAgent
that referenced
this pull request
May 18, 2026
PR lsdefine#360 disabled Textual mouse support on darwin (run(mouse=False)) to keep terminal-native selection working. Side effect: ?1006 SGR mouse was never enabled, while macOS Terminal.app / iTerm2 default ?1007 (alternate scroll mode) translated wheel events into Up/Down keys — which then triggered the newly added input-history navigation. Re-enable mouse globally and explicitly disable ?1007 on mount so wheel events flow through the SGR channel without spawning duplicate arrow keys. Keyboard Up/Down history navigation is unaffected. The ?1007 disable is a no-op on Linux / Windows Terminal where it defaults off.
lsdefine
pushed a commit
that referenced
this pull request
Jul 23, 2026
PR #360 disabled Textual mouse support on darwin (run(mouse=False)) to keep terminal-native selection working. Side effect: ?1006 SGR mouse was never enabled, while macOS Terminal.app / iTerm2 default ?1007 (alternate scroll mode) translated wheel events into Up/Down keys — which then triggered the newly added input-history navigation. Re-enable mouse globally and explicitly disable ?1007 on mount so wheel events flow through the SGR channel without spawning duplicate arrow keys. Keyboard Up/Down history navigation is unaffected. The ?1007 disable is a no-op on Linux / Windows Terminal where it defaults off.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR #360 disabled Textual mouse support on darwin (run(mouse=False)) to keep terminal-native selection working. Side effect: ?1006 SGR mouse was never enabled, while macOS Terminal.app / iTerm2 default "?1007" (alternate scroll mode) translated wheel events into Up/Down keys — which then triggered the newly added input-history navigation.
Re-enable mouse globally and explicitly disable "?1007" on mount so wheel events flow through the SGR channel without spawning duplicate arrow keys. Keyboard Up/Down history navigation is unaffected. The "?1007" disable is a no-op on Linux / Windows Terminal where it defaults off.