fix(ui): #139 sheets size themselves; #141 waybar clicks stop reading the env
Some checks failed
Check / eval (push) Has been cancelled
Some checks failed
Check / eval (push) Has been cancelled
#139 — calcurse/doctor floated full-screen. Two faults stacked, which is why it looked like the float rules were dead: 1. Hyprland 0.55.4 silently ignores percentage `size` rules. Matrix on hardware (both orders, kitty memory off): `size 60% 65%` never applies, `size 1536 936` applies either way, configerrors empty both times. Rule order was a red herring. 2. Kitty defaults to remember_window_size=yes and replays the last OS window's size into every float — so after a tiled terminal, a sheet opens maximized. This is the Ghostty regression: Ghostty had no such memory, so fault 1 stayed invisible until #95. Fix: remember_window_size=no (floats must be deterministic) and the sheets ask for their own size — term-sheet.nix reads the focused monitor and hands kitty the px, because px in a rule cannot mean "a fraction of *this* screen" and one pair cannot serve 2560x1440 and the 1366x768 Acer (#131). Those windows keep float/center and deliberately carry no size rule. #141 — the updates click did nothing: whole-swaps hand-wrote `sh -c '$TERMINAL …'` and Waybar has no TERMINAL (home.sessionVariables → login shells only; the bar is spawned by Hyprland). Fixed at the root: `nomarchy-updates upgrade-window` opens its own window, so all five call sites name one env-free command and a theme file stops having an opinion about terminals. checks.waybar-swap-env guards the class. Bernardo asked mid-task for the update window to float — it is now the third caller of the sheet helper (com.nomarchy.updates, 45%x50%). V3 on the dev box: calendar 1536x936, doctor 1408x1008, updates 1152x720 — exactly the intended fractions, floating and centred; #141 driven under `env -i` with no TERMINAL, matching Waybar's real environment; the guard proven by reintroducing the bug. Acer V3 queued. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -427,6 +427,47 @@ Design/decision records and a running log of shipped work (items marked
|
||||
default `$TERMINAL` / SUPER+Return, doctor + calendar + what-changed use
|
||||
`kitty --class=com.nomarchy.*`. Ghostty module and install-time GL probe
|
||||
removed. V3: Acer SUPER+Return + doctor float.
|
||||
- ✓ **The floating sheets got their size back (#139, 2026-07-16):** Bernardo:
|
||||
calcurse and the doctor sheet float, but full-screen — the reduced size
|
||||
Ghostty used to give them was gone. Two independent faults, stacked, which
|
||||
is why it read as "the float rules are dead" when they were not.
|
||||
**(1)** Hyprland 0.55.4 silently ignores a *percentage* `size` rule. Matrix
|
||||
on hardware, both rule orders, Kitty's memory disabled so nothing could mask
|
||||
it: `size 60% 65%` never applies, `size 1536 936` applies in either order,
|
||||
and `hyprctl configerrors` is empty both ways — which is how it slipped
|
||||
through the post-0.53 rule rewrite. Order turned out to be a red herring.
|
||||
**(2)** Kitty defaults to `remember_window_size yes` and replays the last OS
|
||||
window's size (`~/.cache/kitty/main.json`) into the next one, so with (1)
|
||||
applying nothing, every sheet inherited whatever the last terminal was —
|
||||
after a tiled one, the whole screen. **This is the Ghostty regression**: it
|
||||
kept no such memory, so (1) was invisible until #95 made Kitty the only
|
||||
terminal. Fix: `remember_window_size no` (floats must be deterministic; the
|
||||
compositor sizes tiled windows anyway) and the sheets now ask for their own
|
||||
size — `modules/home/term-sheet.nix` reads the focused monitor and hands
|
||||
Kitty the px, because px in a rule cannot mean "a fraction of *this* screen"
|
||||
and one pair cannot serve a 2560×1440 desk monitor and the 1366×768 Acer
|
||||
(#131). Those windows therefore carry float/center rules and deliberately no
|
||||
`size` rule. Measured after: calendar 1536×936 = exactly 60%×65%, doctor
|
||||
1408×1008 = 55%×70%, both centred in the Waybar work area.
|
||||
- ✓ **Waybar whole-swap on-clicks lost their environment (#141, 2026-07-16):**
|
||||
clicking the updates module did nothing. Not an updates bug — a **parity**
|
||||
break: the generated module bakes the terminal in at eval time, but the four
|
||||
whole-swaps hand-wrote `sh -c '$TERMINAL -e nomarchy-updates upgrade'`, and
|
||||
Waybar has no `TERMINAL`. It is a `home.sessionVariables` entry, so login
|
||||
shells get it and the Hyprland-spawned bar does not; the click expanded to
|
||||
`sh -c ' -e nomarchy-updates upgrade'` and failed silently, with no error and
|
||||
no toast. Fix at the root rather than in five places: `nomarchy-updates
|
||||
upgrade-window` opens its own terminal, so every caller names one env-free
|
||||
command and a *theme* file stops having an opinion about terminals.
|
||||
`checks.waybar-swap-env` guards the class — no whole-swap `exec`/`on-click`
|
||||
may read an env var (`$name`; `$1` positionals stay legal) — and was proven
|
||||
by reintroducing the bug and watching it fail. The lesson generalises past
|
||||
Waybar: **anything Hyprland spawns has no login shell**, so a hand-written
|
||||
command that works in your terminal proves nothing about the bar. Bernardo
|
||||
asked for the window to be a small float while this was in flight, so it is
|
||||
a classed sheet (`com.nomarchy.updates`, 45%×50%) like the calendar and
|
||||
doctor — the third caller of #139's helper, which is what made it a one-line
|
||||
ask rather than a fourth copy of the sizing logic.
|
||||
- ✓ **GTK dialog button labels (#98):** Stylix always set `gtk-theme-name=
|
||||
adw-gtk3` (light sheet) while recoloring tokens for dark palettes — light
|
||||
sheet hardcodes near-black button text → black-on-dark in GTK dialogs
|
||||
|
||||
Reference in New Issue
Block a user