Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add basic dimming functionality #2751

Closed
wants to merge 12 commits into from
Prev Previous commit
Next Next commit
adds dimming documentation
  • Loading branch information
farwyler committed Jul 2, 2022
commit 449ce13cb614d56d9a1687b4b79978d0f67ef923
21 changes: 21 additions & 0 deletions book/src/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -185,4 +185,25 @@ Example:
[editor.indent-guides]
render = true
character = "╎"

### `[editor.dim]` Section

Enable dimming in certain areas. Disabled by default. Enable by assigning:
- 0 = set text modifier flag DIM
- negative value = darken colors (-127 = 100% darker)
- positive value = lighten colors (+127 = 100% lighter)

> darken/lighten colors only works with themes that set rgb colors, not indexed colors.

| Key | Description | Default |
|--|--|---------|
| `overlay-backdrops` | Enable dimming and set shade of content behind overlays. | `None` |
| `unfocused-views`| Enable dimming and set shade of unfocused editor views. | `None` |

```toml
[editor.dim]
# darken backdrop of overlays
overlay-backdrops = -25
# dim fg color of unfocused views
unfocused-views = 0
```