Repository navigation
feat: zoom terminal font with Ctrl + wheel and trackpad pinch - #2
Merged
Merged
Conversation
luis-jagella
marked this pull request as ready for review
October 8, 2026 13:05
Collaborator
|
im skeptical, need gifs |
Contributor
Author
GIFs of my finger scrolling, or the terminal zooming in and out? |
Collaborator
yes also, which model did this? |
Collaborator
|
also is trackpad 'pinch' motion supported? if not, make so |
Contributor
Author
GPT-6.1 Sol on max reasoning |
Contributor
Author
and I kept the implementation scoped to the terminal repo. |
Contributor
Author
added in a6b3792: native pinch on macOS, and Ctrl + wheel emulation on compatible Windows trackpads. Automated Windows validation passed; physical trackpad testing on both is still pending. |
Contributor
Author
xF6IyOV.mp4 |
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.
Ctrl + mouse wheel over a terminal pane now adjusts the terminal font size, matching Ctrl+Plus/Minus. Native trackpad pinch events also change the font proportionally, without requiring Ctrl. Both use the existing 8–28 point range, save the setting and repaint the terminal. Ordinary scrolling still navigates the transcript.
Pinch events are handled over a terminal pane in the focused window. The app combines the scale factors received in a frame and prevents a zoom gesture from moving the transcript or its scrollbars. Keyboard, wheel and pinch share the font update path, so pinch scaling also respects the independent interface scale.
Platform support: egui 0.28 translates winit's native trackpad magnification into
Event::Zoomon macOS. Windows trackpads that emulate pinch as Ctrl + wheel use the existing wheel path; the tests include releasing the emulated Ctrl and returning to ordinary scrolling. See egui's integration, winit's native platform support and a Windows gesture event trace. This PR does not add a native OS gesture backend for Windows/Linux, and physical trackpad testing is still needed on Windows and macOS.Validation: