workspace: Add settings to dim inactive panes and highlight active pane (#18968)

Closes #12529
Closes #8639

Release Notes:

- Added option to dim inactive panes
([#12529](https://github.com/zed-industries/zed/issues/12529))
- Added option to highlight active pane with a border
([#8639](https://github.com/zed-industries/zed/issues/8639))

BREAKING: `active_pane_magnification` value is no longer used, it should
be migrated to `active_pane_modifiers.magnification`


![panes](https://github.com/user-attachments/assets/b19959bc-4c06-4320-be36-412113143af5)

> note: don't know much rust, so I wouldn't be surprised if stuff can be
done much better, happy to update things after the review.
Also, wasn't sure about introducing the new object in the settings, but
it felt better than adding two more keys to the root, let me know what
you think and if there's a better way to do this. Also happy to get
feedback on the text itself, as I didn't spend much thinking how to
document this.
This commit is contained in:
Alex Viscreanu 2024-11-05 16:26:07 +01:00 committed by GitHub
parent b8501199c2
commit bc3550d991
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 108 additions and 18 deletions

View file

@ -29,10 +29,26 @@ Extensions that provide language servers may also provide default settings for t
# Settings
## Active Pane Magnification
## Active Pane Modifiers
Styling settings applied to the active pane.
### Magnification
- Description: Scale by which to zoom the active pane. When set to `1.0`, the active pane has the same size as others, but when set to a larger value, the active pane takes up more space.
- Setting: `active_pane_magnification`
- Setting: `magnification`
- Default: `1.0`
### Border size
- Description: Size of the border surrounding the active pane. When set to 0, the active pane doesn't have any border. The border is drawn inset.
- Setting: `border_size`
- Default: `0.0`
### Inactive Opacity
- Description: Opacity of inactive panels. When set to 1.0, the inactive panes have the same opacity as the active one. If set to 0, the inactive panes content will not be visible at all. Values are clamped to the [0.0, 1.0] range.
- Setting: `inactive_opacity`
- Default: `1.0`
**Options**