diff options
| author | user <user@clank> | 2026-08-13 20:36:45 +0200 |
|---|---|---|
| committer | user <user@clank> | 2026-08-13 20:36:45 +0200 |
| commit | 91f40dccd9def02d147ea41615f7bc159cb306a6 (patch) | |
| tree | 525c568778860b404620ff6d4581e91cb5c07357 /docs | |
| parent | sl0p: the plugins we ship do not ask for permission (diff) | |
| download | sl0ppi-91f40dccd9def02d147ea41615f7bc159cb306a6.tar.gz sl0ppi-91f40dccd9def02d147ea41615f7bc159cb306a6.tar.xz sl0ppi-91f40dccd9def02d147ea41615f7bc159cb306a6.zip | |
sl0p(bar): a new-tab button, and margins that match the pane gap
First pass of the status bar overhaul, in the zjstatus fork plus the layout
that configures it.
margin_left / margin_right: the bar is a full-width pane while every pane above
it is inset by the pane gap, so its ends stuck out past every frame on screen.
The margins are applied by rendering into an inset viewport (inset_state),
which is the same thing click positions are translated by -- so what is drawn
and what is clickable come from one definition. That is the split button's
lesson applied before shipping rather than after.
{new_tab}: a clickable button that opens a tab and focuses it, with no name and
no cwd, i.e. exactly what the `n` binding in TAB mode does. Clicking a tab
already switches to it and double-clicking renames it; making one was the hole
in the strip. Rendering and hit-testing are the same measured string here, so
the button covers exactly the columns it draws.
Both keys are inert when unset, so an unmodified zjstatus config renders
identically.
packaging/checks/status-bar-live.py reads the bar off a real session and
asserts it spans exactly the columns the pane frames span, clicks the + and
expects one more tab, then clicks beside it and expects none. Confirmed by
setting the margins to 0 and watching the span assertion fail: (0, 99) against
the frames' (2, 97).
The check counts painted cells rather than ink, because a bar segment begins
with a padding space inside its coloured pill -- strip the colour and the left
edge reads one column off, which is half the margin being measured.
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/roadmap.md | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/docs/roadmap.md b/docs/roadmap.md index ef71070..3588e95 100644 --- a/docs/roadmap.md +++ b/docs/roadmap.md @@ -293,6 +293,48 @@ runs without the prompt, then launches the *same file* from outside that dir and asserts it still asks. Confirmed by disabling the rule and watching the first half fail with the exact "asks permission to ... Allow? (y/n)" screen. +## Status bar: first pass of the overhaul + +Two things, both in `sl0pstatus/` (our zjstatus fork) plus the layout that +configures it: + +- **`margin_left` / `margin_right`** — the bar is a full-width pane while every + pane above it is inset by the pane gap, so its ends stuck out past every frame + on screen. The margins pull its content in. They are applied by rendering the + bar into an inset viewport (`ModuleConfig::inset_state`), which is also what + click positions are translated by, so the drawing and the hit-testing cannot + disagree — the lesson from the split button, applied up front this time. +- **`{new_tab}`** — a clickable button that opens a tab and focuses it, the + mouse spelling of the `n` binding in TAB mode. Clicking a tab already switches + to it and double-clicking renames it; making one was the gap. + +Keep `margin_*` in step with `config.kdl`'s `gap` x `gap_aspect` (1 x 2 = 2). +The plugin cannot see that config, and inferring it from pane geometry would +break on the first borderless pane. + +**How to re-run the check**: + +```bash +make check-live # includes packaging/checks/status-bar-live.py +``` + +It reads the bar off a real session and asserts it spans *exactly* the columns +the pane frames span (2..97 at 100 columns), then clicks the `+` and expects one +more tab, and clicks beside it and expects none. Confirmed by setting the +margins to 0 and watching the span assertion fail with `(0, 99)` against the +frames' `(2, 97)`. + +That check tracks painted cells, not ink: a bar segment starts with a padding +space inside its coloured pill, so stripping colour puts the left edge one +column off — the exact size of the thing being measured. + +### Still open on the bar + +The request was "quite a bit of an overhaul", and this is the first pass. Not +done, and worth deciding before more work: whether the bar should be a framed +box in the pane style (rounded corners, its own gap) rather than a single line; +whether it should be multi-row; what else belongs on it. + ## Standing risks **`sl0ppij/target` is a symlink to `~/lol/zellij/target`.** Introduced when the |
