Files
tri 09c1e312cb feat(helium): switch to the GTK theme with KWin title buttons
Helium now takes its colors from Breeze GTK instead of a generated
theme extension, which reset the GTK theme on every launch.

- Import window_decorations.css from gtk.css so Helium, which doesn't
  load kde-gtk-config's GTK module, draws the KWin title buttons
  instead of Breeze GTK's round ones.
- Add chromium.css to give the compact layout's address bar and
  button segment the title bar color, so the tab strip is one color.
- Disable WaylandWpColorManagerV1 so KWin doesn't lift Helium's dark
  grays (40 -> 44) and the strip matches KDE title bars.
- Drop the Helium theme from build.py and the helium package.
2026-11-03 22:18:52 +07:00

134 lines
7.2 KiB
Markdown

# Darwin Breeze
Breeze for KDE Plasma 6 in the macOS dark system colors, with Helium, T3 Code,
VS Code and Telegram themed from the same colors.
Only the colors change. Breeze still draws the widgets and the title bar, and
the window buttons stay on the right.
- Selection and focus rings use the macOS blue, `#007AFF`.
- The title bar has the same color as the toolbar below it, so the two read as
one strip.
- When a window loses focus, its selection turns gray, as on macOS.
- Errors, warnings, success text and links use Apple's system red, orange,
green, blue and purple.
## Install
From `~/.dotfiles`:
```sh
stow -d kde -t "$HOME" theme
./kde/theme/apply.sh
```
`apply.sh` regenerates the app themes, applies the global theme, hides the
line under the title bar, turns off the wallpaper accent color, gives Helium
the KWin title buttons and an even tab strip, publishes the T3 Code theme and
installs the VS Code extension. Restart Helium afterwards; T3 Code switches on its own. In VS
Code, pick "Darwin Breeze Dark" once under Preferences → Color Theme; after
later color changes, run Developer: Reload Window.
Telegram has to import its theme by hand: Settings → Chat Settings → Chat
background → Choose from file, then pick
`kde/theme/telegram/DarwinBreezeDark.tdesktop-theme` and Apply. Import it
again after the colors change.
## Changing colors
The color scheme is the only place colors are defined:
```
kde/theme/.local/share/color-schemes/DarwinBreezeDark.colors
```
Edit it, then run `./kde/theme/apply.sh` again. Everything else follows:
| App | How it gets the colors |
| --------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
| Qt / KDE apps | the color scheme itself |
| GTK apps | Breeze GTK, which `kde-gtk-config` syncs from the scheme |
| Tray icons in `kde/tray-icons/` | `ColorScheme-Text`, recolored by Plasma |
| Helium | Breeze GTK, through Helium's GTK theme (see [Helium notes](#helium-notes)) |
| T3 Code | `t3/darwin-breeze.json`, generated by `build.py` and published with `t3 theme set` |
| VS Code | `vscode/package.json` and `vscode/themes/`, generated by `build.py`, packed into `darwin-breeze.vsix` and installed by `apply.sh` |
| Telegram | `telegram/DarwinBreezeDark.tdesktop-theme`, built by `build.py` and imported by hand |
The generated text files are committed so that `stow` alone gives a working
setup; the binary packages (Telegram's `.tdesktop-theme`, VS Code's `.vsix`)
are built by `build.py` instead. Don't edit generated files by hand.
## T3 Code notes
- T3 Code ignores symlinked theme files, so the theme isn't stowed;
`apply.sh` publishes a copy into `~/.t3/userdata/themes/`.
- Every slot of the T3 theme maps to a role in the color scheme (see `t3()` in
`build.py`), so a new slot or a different mapping is a change there, not a
hand-edited color.
## VS Code notes
- The workbench colors start from VS Code's own default dark theme, Dark 2026
(vendored in `vscode/base/` with the themes it includes). It already lays
out its grays as the scheme does: the editor darkest, the chrome around it
lighter, widgets lighter still. Each of those becomes the matching scheme
gray and the grays between them are interpolated. Other colors take the
hue of the matching Apple color and keep their lightness and saturation.
Keys with an exact role, such as buttons, badges, the active tab's top
border and the git colors, are set directly (`vscode()` in `build.py`).
- Syntax colors are Pierre Dark's, the theme T3 Code highlights code with
(`vscode/base/pierre-dark.json`, taken from T3 Code). They are used as they
are, without gamma compensation, so code looks the same in both apps.
- The terminal palette is generated from the color scheme.
- VS Code is Electron, so its workbench colors get the same gamma
compensation as T3 Code.
- The `.vsix` isn't committed; `build.py` packs it from `vscode/`.
## Telegram notes
- Telegram has some 600 color keys and the scheme has roles for only a few
dozen of them (`telegram()` in `build.py`). The rest start from Telegram's
own night theme, vendored as `telegram/night.tdesktop-palette`: its
blue-tinted grays become scheme grays of the same brightness and its blues
take the macOS blue's hue. Other colors, such as the reds, greens and name
colors, are kept as night has them.
- The chat list, top bar and compose bar use the window color; the chat
behind the bubbles and the folder strip use the darker view color.
- Telegram is a Qt app, so unlike T3 Code and VS Code it needs no gamma
compensation.
- The `.tdesktop-theme` is a zip, so it isn't committed; `build.py` builds it
from the night palette and the color scheme.
## Helium notes
- Helium uses the GTK theme (Settings → Appearance → Theme: GTK) with "Use
system title bar and borders" off, so the tab strip doubles as the title
bar. Its colors come from Breeze GTK, which `kde-gtk-config` syncs from
the scheme; there is no Helium theme to generate.
- With the system title bar off, Helium draws the window buttons through
GTK. `kde-gtk-config` renders the KWin buttons into
`~/.config/gtk-3.0/window_decorations.css`, but hands that file to GTK apps
through a GTK module that Helium doesn't load, so Helium would show Breeze
GTK's own round buttons instead. `apply.sh` imports the file from `gtk.css`
so Helium picks it up too.
- In the compact layout, the address bar takes GTK's text field color and the
segment with the extension and window buttons takes the window color, which
Chromium resolves to the darker view color. `.config/gtk-3.0/chromium.css`
gives both the title bar color, and `apply.sh` imports it from `gtk.css`.
Chromium adds a `chromium` class to every GTK node it reads colors from, so
the rules reach Helium and no other GTK app.
- Chromium tags its output as sRGB and KWin shows it with a gamma 2.2 curve,
which lifts dark grays (40 becomes 44). T3 Code and VS Code get
pre-compensated colors from `build.py`; Helium instead runs with
`--disable-features=WaylandWpColorManagerV1`, so its surfaces go untagged
and show the GTK colors as they are.
## When the colors don't show up
- In System Settings → Colors, take the accent color from the color scheme. A
custom accent, or one taken from the wallpaper, replaces the blue.
- Use the Plasma style called "Breeze". "Breeze Dark" and "Breeze Light" carry
their own colors, so panels and popups ignore the scheme.
- GTK apps follow the scheme only with the Breeze GTK theme. Flatpak apps also
need `org.gtk.Gtk3theme.Breeze` installed.