Customize the bar
Choose what appearsPermalink to Choose what appears#
The built-in bar shows workspaces, layout, clock, brightness, battery, volume, network, removable drives, and nightlight. Missing devices have no cell. Each enabled output gets its own row. Choose show audio devices from the launcher to manage sound devices. The network cell currently shows status only. There's no system tray yet, but one is planned.
(config
bar: (bar height: 30 position: 'top outputs: '("*")
style: (bar-style font: "JetBrains Mono 9"
background: #x232635ef foreground: #xffffffff
padding: '(0 8 0 8))
left: (list (workspaces-section) (layout-section))
center: (list (clock-section format: "%a %d %b %H:%M"))
right: (list (volume-section) (network-section)
(drives-section) (nightlight-section))))The default row is 22 logical pixels high; increase the height for larger fonts. Set bar: #f if you'd rather use an external bar or panel program. Configuration errors still get their independent, clickable error strip.
Show it only while holding ModPermalink to Show it only while holding Mod#
Set visibility: 'overlay on the bar to show it while Mod is held, without reserving workspace space. 'always reserves its strip after other layer-shell exclusive zones. Position can be 'top or 'bottom; hide-fullscreen?: #t hides it for fullscreen windows. Try an override in the running session:
tessera eval "(bar-visibility! 'overlay)"
tessera eval "(bar-toggle-visibility!)"
tessera eval '(bar-visibility)'The override lasts until a successful reload or configuration apply. Theme changes preserve it. These calls can't enable a bar configured as false. Click the error strip or call bar-dismiss-error! to dismiss it.
Style sections and workspacesPermalink to Style sections and workspaces#
Styles inherit from bar to section to item. bar-style accepts font, foreground, background, padding, margin, border-width, border-color, radius, separator, align, min-width, max-width, and ellipsis: 'end. Colors are straight RGBA integers; padding and margin use top, right, bottom, left in logical pixels. A style can also be a procedure of the detached context.
Empty workspaces are hidden except the one visible on that output. Set show-empty?: #t on workspaces-section to show them all. Its focused-style:, visible-style:, and urgent-style: distinguish the focused workspace, one visible elsewhere, and one requesting attention. Urgency takes priority. selected-style: is an alias for focused-style; focused-style wins if both are present.
Built-in status and layout sections accept icons?: #f for word labels. Use network-section detail: #t to show the connection name. Wi-Fi bars indicate signal; ?, !, …, and ~ mean unknown, sign-in required, connecting, and stale. Drives show mounted/total counts. Nightlight's ! means gamma is unavailable or rejected; ext means another gamma client controls it.
Write a small providerPermalink to Write a small provider#
A section provider receives a detached context and returns text, bar items, or a section-result containing content and new state. Keep it short: providers run on the session's serialized policy consumer. Use events or an interval to update it, rather than waiting inside a callback.
(config
bar: (bar
left: (list (workspaces-section))
center: (list (clock-section format: "%I:%M:%S %p" interval: 1))
right: (list
(section 'reminder
text: (lambda (context) "Take a break")
events: '(workspace focus)))))
Contexts expose output, workspace, focused-window, time, cached services, previous result, section state, and process data. on-click: receives the context and a vector containing Linux button code and item ID. Item actions take priority over section handlers. A compatible reload preserves section state by ID, separately per output. Provider errors keep the last good content and show a dismissible error.
For an external producer, use process-source with explicit argv, mode: 'continuous or 'one-shot, format: 'json-line or a line format, and a timeout. JSON records require text and may include tooltip, class, state, and percentage. Blank JSON lines leave the display alone. Read the latest result through bar-context-process. bar-refresh! explicitly refreshes a section and its source.