fix: kitty status bar clock — redraw via add_timer, drop bogus tab_bar_timeout

kitty has no tab_bar_timeout option (ignored with a warning), so the clock/CPU/mem
only refreshed on tab changes. tab_bar.py now registers a repeating 10s timer that
marks every tab bar dirty. Verified in Xvfb: idle window's clock ticked 16:21 -> 16:22.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Mortdecai
2026-09-29 16:22:25 -04:00
parent 0c0066fef1
commit b339b3e738
3 changed files with 18 additions and 4 deletions
+2 -2
View File
@@ -114,12 +114,12 @@ All read from `/proc` (no subprocess overhead except git):
- **Colors**: Edit `_ORANGE`, `_DIM`, `_TAB_BG`, `_BAR_BG` in `tab_bar.py`
- **Status items**: Add/remove cells in the `if is_last:` block in `tab_bar.py`
- **Refresh rate**: Change `tab_bar_timeout` in `kitty-theme.conf` (seconds)
- **Refresh rate**: Change `REFRESH_SECS` in `tab_bar.py` (seconds)
- **User prefix**: The `_prefix` logic in `tab_bar.py` shows `user@` for non-seth users
## Troubleshooting
- **Icons show as boxes**: Nerd Font not installed or kitty not using it. Check `font_family` in kitty.conf.
- **Status bar not updating**: Ensure `tab_bar_timeout 60.0` is set in kitty-theme.conf.
- **Status bar not updating**: `REFRESH_SECS` timer in `tab_bar.py` drives redraws (kitty has no `tab_bar_timeout` option); check `kitty` stderr for tab_bar.py errors.
- **F12 does nothing**: Ensure `allow_remote_control yes` and `listen_on unix:/tmp/kitty-{kitty_pid}` are in config. Restart kitty (not just reload).
- **CPU shows "..."**: Normal on first draw — needs two samples to compute delta.