aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--AGENTS.md6
-rwxr-xr-xbin/udt-palette11
2 files changed, 13 insertions, 4 deletions
diff --git a/AGENTS.md b/AGENTS.md
index 35fde22..67e3440 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -256,7 +256,11 @@ them by exit code: rofi exits non-zero for ordinary reasons such as Escape.
rofi does not expand `~` inside a `url()`.
- After editing anything under `rofi/udt/` or `palette/`, run `./install.sh`.
- `bin/udt-palette --selftest` resolves every role in every scheme. Run it
- after touching a palette, a role map, or the generator.
+ after touching a palette, a role map, or the generator, and before
+ regenerating: `palette.rasi` is live the moment it is written. A name in
+ `ROFI_NAMES` must be letters and digits only; rofi rejects `term_blue` and
+ then no theme on the desktop parses, which the selftest catches and a
+ regeneration does not.
- `bin/udt-accent --selftest` covers the snapping logic. Run it after touching
the colour maths.
diff --git a/bin/udt-palette b/bin/udt-palette
index 04451f7..f603899 100755
--- a/bin/udt-palette
+++ b/bin/udt-palette
@@ -145,6 +145,12 @@ ROFI_NAMES = [
("overlay0", "fg_faint"), ("overlay1", "mid_low"), ("overlay2", "mid_high"),
("red", "critical"), ("green", "success"), ("yellow", "warning"),
("teal", "info"), ("blue", "border_active"), ("lavender", "accent"),
+ # Not referenced by any rofi theme. Here because palette.rasi is also
+ # what udt-accent forwards to quickshell, whose keybind reminder draws
+ # the macropad's orange, purple and blue keycaps in them. "blue" above is
+ # the active border, which is magenta under candy-night; termblue is the
+ # terminal's blue, a real blue in every scheme but Dracula, which has none.
+ ("peach", "peach"), ("mauve", "highlight"), ("termblue", "blue"),
]
@@ -192,11 +198,10 @@ def gen_waybar(res, scheme, palette):
palette_rows = "\n".join(f"@define-color {k:<12}{v};"
for k, v in sorted(palette.items()))
- # The names the hand-edited stylesheets reference. ROFI_NAMES already maps
- # most of them; mauve is the one waybar uses and rofi does not.
+ # The names the hand-edited stylesheets reference, all in ROFI_NAMES.
compat_rows = "\n".join(
f"@define-color {name:<12}{rgba(res[role])};"
- for name, role in [*ROFI_NAMES, ("mauve", "highlight")])
+ for name, role in ROFI_NAMES)
def emit(role, css_name=None):
c = res[role]