Files
Andri Soone 504a7f2cf2 Allow mouse wheel zoom in terminals and diff views (#66296)
## Summary

I like to use the mouse wheel zoom functionality on the code to change
the size in Zed. It's very useful when switching between screens of
different sizes for example.

Unfortunately it only works when a file is opened, not in the diff view
or the terminal, and diff view is pretty much the only view I use
nowadays. So whenever I want to change the font sizes, I have to click
"Open file" to zoom there.

This has been annoying me for months so I fixed it with the help of
Claude Opus 5.5 High.

The agent diff and terminals in the agent panel still don't zoom on
purpose (decision made in #53598 apparently).

### Before


https://github.com/user-attachments/assets/eb47fae2-d82f-4bfc-adbe-3a3c7223bacb

### After


https://github.com/user-attachments/assets/84cd86ae-d589-457b-8ab0-733cfb60177f

## Testing

I tested on macOS 27.0.1 (26A434) and Zed 1.27.0 (37faef81f7).

### Reproduction steps
- Enable `mouse_wheel_zoom` in settings.
- Open any file diff and the terminal view.
- Do Cmd + Scroll (or Ctrl + Scroll on non-Macs) in the code and
terminal.
- Previously, they didn't change the font sizes. After this commit they
do.

## Self-review

- [x] I've reviewed my diff for quality, security, reliability, and
performance.
- [x] UI changes follow the
[checklist](https://zed.dev/docs/development/ui-checklist).
- [x] Tests cover the new or changed behavior.

Release Notes:

- Added support for mouse-wheel font zoom in diff views and terminals.

---------

Co-authored-by: dino <dinojoaocosta@gmail.com>
2026-11-02 22:26:26 +00:00
..