Dedicated one-row status footer rendered below the input box.
Codex-style three-region layout:
[LEFT] [CENTER] [RIGHT]
glm-5.1 (balanced) total tok 12000→800 (cached 8000) $0.04
Each region holds a list of {:text :fg :bold? :region :priority}
spans separated by ' / ' in muted color. The full segment list is
built up-front and shrunk by dropping the highest :priority
number (least important) until it fits the available width.
Footer deliberately avoids transient run-state and cancellation banners. Those live in the assistant bubble and host notifications; this row keeps slow-changing identity + budget bits.
Run-state (spinner, iteration counter, elapsed time, current
phase) lives EXCLUSIVELY in the assistant bubble's progress->text
block. Putting it in the footer too was a duplicate - same
⠋ 11.2s showing twice on screen. The footer keeps slow-changing
identity + budget bits; the bubble keeps the live activity story
(«Vis is thinking (iter 3)... 4.1s / Esc to cancel»).
The first footer row carries repository context on the right: repo/branch, one compact changed-file count, and ahead/behind counts when an upstream is configured. The second footer row carries provider budgets and cumulative usage under that git context. Git status is cached briefly so repainting the TUI does not shell out to git on every frame.
Every numeric format uses Locale/ROOT so a Polish JVM doesn't
produce mixed 5,8k next to English k. The previous footer
embedded the status into the input box's bottom border via
embed-in-bar, which forced single-color rendering and was the
reason run-state had to live inside the assistant bubble; this
namespace replaces that whole path.
Dedicated one-row status footer rendered below the input box.
Codex-style three-region layout:
[LEFT] [CENTER] [RIGHT]
glm-5.1 (balanced) total tok 12000→800 (cached 8000) $0.04
Each region holds a list of `{:text :fg :bold? :region :priority}`
spans separated by ' / ' in muted color. The full segment list is
built up-front and shrunk by dropping the highest `:priority`
number (least important) until it fits the available width.
Footer deliberately avoids transient run-state and cancellation
banners. Those live in the assistant bubble and host notifications;
this row keeps slow-changing identity + budget bits.
Run-state (spinner, iteration counter, elapsed time, current
phase) lives EXCLUSIVELY in the assistant bubble's `progress->text`
block. Putting it in the footer too was a duplicate - same
`⠋ 11.2s` showing twice on screen. The footer keeps slow-changing
identity + budget bits; the bubble keeps the live activity story
(«Vis is thinking (iter 3)... 4.1s / Esc to cancel»).
The first footer row carries repository context on the right:
repo/branch, one compact changed-file count, and ahead/behind counts
when an upstream is configured. The second footer row carries provider
budgets and cumulative usage under that git context. Git status is
cached briefly so repainting the TUI does not shell out to git on every frame.
Every numeric format uses `Locale/ROOT` so a Polish JVM doesn't
produce mixed `5,8k` next to English `k`. The previous footer
embedded the status into the input box's bottom border via
`embed-in-bar`, which forced single-color rendering and was the
reason run-state had to live inside the assistant bubble; this
namespace replaces that whole path.(draw-echo-area! g db echo-row cols _now-ms)Emacs echo area / minibuffer analogue: ONE flat row directly above the
input box. Terminal background, NO box and NO side rails — the input box
owns its own border below. Blank until echo-segments has something to
say (a chord in progress, the mid-turn cancel hint, or a transient
message). Left-aligned at the input's horizontal pad so it tracks the
prompt column.
Emacs echo area / minibuffer analogue: ONE flat row directly above the input box. Terminal background, NO box and NO side rails — the input box owns its own border below. Blank until `echo-segments` has something to say (a chord in progress, the mid-turn cancel hint, or a transient message). Left-aligned at the input's horizontal pad so it tracks the prompt column.
(draw-footer! g db footer-row cols now-ms)Paint the two footer rows starting at footer-row, full width cols. Pure draw -
reads db once, computes segments, fits to width, writes cells.
Safe to call every frame (cheap; no allocations on the hot path
beyond the spans vector).
Paint the two footer rows starting at `footer-row`, full width `cols`. Pure draw - reads `db` once, computes segments, fits to width, writes cells. Safe to call every frame (cheap; no allocations on the hot path beyond the spans vector).
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |