aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoruser <user@clank>2026-08-08 21:19:04 +0200
committeruser <user@clank>2026-08-08 21:19:04 +0200
commit72d5201b52624a5cf3e530397b909c2f3d008dcf (patch)
tree882187ac08cb128bc2f5359d4c4b1a9dad019d59
parentsl0p: CSS-style 1/2/4-value shorthand for inner padding (diff)
downloadsl0ppij-72d5201b52624a5cf3e530397b909c2f3d008dcf.tar.gz
sl0ppij-72d5201b52624a5cf3e530397b909c2f3d008dcf.tar.xz
sl0ppij-72d5201b52624a5cf3e530397b909c2f3d008dcf.zip
docs: prepend sl0ppij fork header to README
Anyone cloning this repo got stock Zellij's README and no indication the binary behaves differently, with the new options discoverable only from commit messages. Documents the four config options, which changes apply live vs need a new session, the fastdev build profile, and the known rough edges. Two corrections while writing it: - The frameless-mode caveat is stated honestly. `padding` DOES still inset content when pane frames are off, but the vacated cells are not repainted because ui/boundaries.rs owns that region, so stale glyphs are expected on resize. That is a real limitation, not the deliberate design the first draft claimed. gap/padding are documented as full-frame only for now. - Deduplicated the borderless-pane comment in both panes, which scripted patching had left repeated three times.
-rw-r--r--README.md104
-rw-r--r--zellij-server/src/panes/plugin_pane.rs10
-rw-r--r--zellij-server/src/panes/terminal_pane.rs4
3 files changed, 108 insertions, 10 deletions
diff --git a/README.md b/README.md
index 1685a1d7..369f2271 100644
--- a/README.md
+++ b/README.md
@@ -1,3 +1,107 @@
+# sl0ppij — an opinionated Zellij fork
+
+> This is **not** upstream Zellij. It is a fork maintained at
+> <https://git.sl0p.foo/sl0ppij.git>, tracking [zellij-org/zellij][upstream] with a
+> small set of opinionated additions, mostly about how panes *look*.
+>
+> Upstream's README follows below, unchanged.
+
+[upstream]: https://github.com/zellij-org/zellij
+
+## What this fork adds
+
+Everything lives in the existing `ui { pane_frames { ... } }` block, and every option
+defaults to upstream behaviour — an unmodified config renders exactly as stock Zellij.
+
+```kdl
+ui {
+ pane_frames {
+ // Where the pane title sits in the frame. Upstream hardcodes it flush
+ // left for full frames. (Frameless mode already centred it.)
+ title_alignment "center" // "left" | "center" | "right" (default: left)
+
+ // Outer gap: real empty terminal between panes, WM style.
+ // Expressed in ROWS. A pane insets right/bottom always and left/top
+ // only at the screen edge, so two neighbours show exactly `gap`
+ // between them -- not double -- and the screen edges match.
+ gap 1 // default: 0
+
+ // Inner padding between a pane's frame and its content.
+ // CSS-style shorthand, but the 4-value order is UP DOWN LEFT RIGHT,
+ // deliberately NOT CSS's clockwise top-right-bottom-left:
+ // padding 1 all four sides
+ // padding 1 2 up/down = 1, left/right = 2
+ // padding 1 2 3 4 up=1 down=2 left=3 right=4
+ padding 1 // default: 0
+
+ // Columns per row. Terminal cells are ~2x taller than they are wide, so
+ // 1 row of gap needs ~2 columns to look like the same distance.
+ // Applies to `gap`, and to the 1-value form of `padding`. The 2- and
+ // 4-value padding forms are taken literally. Set to 1 to disable.
+ gap_aspect 2 // default: 2
+ }
+}
+```
+
+Also in the fork, not configurable:
+
+- A compact scroll indicator (`↑42`) in place of upstream's `SCROLL: 42/1000`, shown
+ only when actually scrolled up rather than whenever scrollback exists.
+- `sl0p.foo` branding in the default tab-bar plugin.
+
+## Which changes apply live
+
+`config.kdl` is watched, but only some things reach a running session:
+
+| change | applies |
+|---|---|
+| `title_alignment`, `gap`, `padding`, `gap_aspect` | **live**, no restart |
+| `rounded_corners`, and other stock options | **live** (upstream behaviour) |
+| anything requiring a new binary | **new session** — a running server keeps its old inode |
+
+## Building
+
+Upstream's `[profile.release]` uses fat LTO and `codegen-units = 1`, which costs ~3
+minutes for a one-line change. For iteration use the `fastdev` profile added here —
+same `opt-level = 3`, no LTO, parallel codegen, incremental cache kept:
+
+```bash
+cargo build --profile fastdev -p zellij # ~3s incremental -> target/fastdev/zellij
+cargo build --release -p zellij # ~3min -> ship this one
+```
+
+See `.fastfeedback/SPEED.md` for narrow test commands, measured timings, and the
+pre-existing test-failure baselines (this tree has failures that are **not** caused by
+the fork — check against `upstream/main` before chasing one).
+
+## Known rough edges
+
+- **Frameless mode is not supported.** `gap` and `padding` are designed for
+ `pane_frame_style "full"`. With `"titles"` or `"none"`, the cells around a pane's
+ content belong to the inter-pane boundary renderer (`ui/boundaries.rs`), which knows
+ nothing about these insets. `padding` still shrinks the content in that mode but the
+ vacated cells are not repainted, so expect stale glyphs when resizing. Use `gap 0`
+ and `padding 0` with frameless pane frames until this is addressed.
+- **Floating panes** get `padding` but no `gap`: they are positioned explicitly, so an
+ inter-pane gap does not apply.
+- **Stacked panes** apply the gap uniformly; stack header spacing may look slightly off
+ at larger gaps.
+- The fork's options are **not** exposed over the plugin protobuf API. Plugins have no
+ use for them and adding proto fields would mean regenerating the committed prost
+ assets in `zellij-utils/assets/prost/`.
+
+## Staying current with upstream
+
+```
+origin ssh://git@git.sl0p.foo:39327/srv/git/sl0ppij.git (this fork; main = fork work)
+upstream https://github.com/zellij-org/zellij.git (vanilla)
+```
+
+The local `main` branch is kept clean on `upstream/main` so fork commits can be rebased
+onto new Zellij releases.
+
+---
+
<h1 align="center">
<br>
<img src="https://raw.githubusercontent.com/zellij-org/zellij/main/assets/logo.png" alt="logo" width="200">
diff --git a/zellij-server/src/panes/plugin_pane.rs b/zellij-server/src/panes/plugin_pane.rs
index 6c1e8707..76a94662 100644
--- a/zellij-server/src/panes/plugin_pane.rs
+++ b/zellij-server/src/panes/plugin_pane.rs
@@ -763,12 +763,10 @@ impl Pane for PluginPane {
self.gap_offset = gap_offset;
}
fn set_content_offset(&mut self, offset: Offset) {
- // see terminal_pane.rs: borderless panes are chrome (this is the one
- // that matters in practice - zjstatus/status-bar/tab-bar are plugins)
- // borderless panes are UI chrome (status bar, tab bar): they are sized
- // exactly to their content, so insetting them makes them vanish
- // borderless panes are UI chrome (status bar, tab bar): they are sized
- // exactly to their content, so insetting them at all makes them vanish
+ // see terminal_pane.rs: borderless panes are chrome and are sized exactly
+ // to their content, so insetting them at all makes them vanish. This is
+ // the impl that matters in practice - zjstatus/status-bar/tab-bar are
+ // all plugin panes.
let inset = if self.borderless {
Offset::default()
} else {
diff --git a/zellij-server/src/panes/terminal_pane.rs b/zellij-server/src/panes/terminal_pane.rs
index 7fb78171..0e2188f2 100644
--- a/zellij-server/src/panes/terminal_pane.rs
+++ b/zellij-server/src/panes/terminal_pane.rs
@@ -982,10 +982,6 @@ impl Pane for TerminalPane {
}
fn set_content_offset(&mut self, offset: Offset) {
// borderless panes are UI chrome (status bar, tab bar): they are sized
- // exactly to their content, so insetting them makes them vanish
- // borderless panes are UI chrome (status bar, tab bar): they are sized
- // exactly to their content, so insetting them makes them vanish
- // borderless panes are UI chrome (status bar, tab bar): they are sized
// exactly to their content, so insetting them at all makes them vanish
let inset = if self.borderless {
Offset::default()