diff options
| author | user <user@clank> | 2026-09-22 15:01:07 +0200 |
|---|---|---|
| committer | user <user@clank> | 2026-09-22 15:01:07 +0200 |
| commit | 43ab0d0c0dc0c79f04c7e70f5ab3b22b3e36e09a (patch) | |
| tree | ba1a5960438c15391fbf1c0a4e0c49421a8c1fcb /config | |
| parent | sidebar: align the numbers by default (diff) | |
| download | slosh-43ab0d0c0dc0c79f04c7e70f5ab3b22b3e36e09a.tar.gz slosh-43ab0d0c0dc0c79f04c7e70f5ab3b22b3e36e09a.tar.xz slosh-43ab0d0c0dc0c79f04c7e70f5ab3b22b3e36e09a.zip | |
sidebar: air inside it, the way panes have padding (tab_bar_padding)
`padding` is a pane's: the ring between a frame and the text it holds, in rows
times gap_aspect so a `1` looks square around a block of prose. Handing the
same knob to the sidebar looked tempting and is wrong twice over. The sidebar
is chrome, not a pane, and its width is fixed by tab_bar_width -- so `padding
1` would quietly eat four of a sixteen-column strip (two cells a side, aspect
included) and shorten every tab name, because somebody wanted their terminal
text to breathe. And its two axes are not one idea: the columns are an indent
for labels, the rows are air above a list.
So tab_bar_padding, its own knob in the family the rest of the sidebar's air
already lives in (tab_bar_pad, tab_gap, newtab_pad), taking the same 1/2/4
CSS-order values as `padding` -- one reader for both, so they cannot drift
into meaning different things -- but counted in cells.
The default `0 1` is what the sidebar already drew: that one column is where
every label's leading space has been hard-coded since the sidebar existed, and
moving it into a setting is what makes `tab_bar_padding 0` possible at all --
names flush against the frame, which was not previously a thing anyone could
ask for. The statuses, the `+ new tab` row and the pane count follow the same
indent, since they were each carrying their own copy of that space.
It is air *inside* the plate: a tab's fill still spans the whole row and the
whole row is still the hit, because the row is what you click and a highlight
that stopped short of the frame would read as a highlighted word rather than a
chosen row. The bottom rows are given up when the strip is short of them, like
every other piece of air in here.
tab_bar_pad is the older name for the top component alone. It still works,
still means exactly that, and wins where a config writes both -- it is the
more specific of the two. The dump writes tab_bar_padding and mentions it.
Diffstat (limited to 'config')
| -rw-r--r-- | config/config.kdl | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/config/config.kdl b/config/config.kdl index acb4366..2ee0fb9 100644 --- a/config/config.kdl +++ b/config/config.kdl @@ -283,6 +283,22 @@ bell_mark "[!]" // The one-row bar with tabs, the new-tab button and the pane count. status_bar true +// Air inside a *sidebar*, between its frame and the list in it: 1, 2 or 4 +// values in CSS order, the same shape `padding` takes. Counted in cells and +// not in rows-times-`gap_aspect`, because the two sides are doing different +// jobs here -- the columns are an indent for labels and statuses, the rows +// are air above the first tab and below the last thing in the strip -- and +// scaling the columns would make `2` mean four of a sixteen-column sidebar. +// +// The one column each side is where every label's leading space used to be +// hard-coded, so `0` is a thing you can now ask for: names against the frame. +// It is air *inside* the plate; a tab's fill still spans the whole row, +// because the row is what you click. +// +// `tab_bar_pad` is the older name for the top of this alone, still honoured, +// and it wins where a config writes both. +tab_bar_padding 0 1 + // Where a tab's number sits in a *sidebar*. The default, "right", puts it at // the far end of the row, so every name starts in the same column and the // numbers line up in one of their own -- a list with a shape rather than a |
