Documentation
¶
Overview ¶
Command compositor is the proof-of-concept for embedding a DEMANDING full-screen child (think Claude Code) in a tuigo TerminalPane and overlaying a dialog on top of it without corrupting the pane. It exercises the three compositor fixes landed in tuigo v0.1.16:
- FIX 1 — Tab reaches the pane. The embedded shell fills most of the screen and GRABS input: Tab and Shift-Tab go to the child (an agent uses them for its own modes), NOT to focus cycling. Focus is switched with a distinct global chord, Ctrl-O (tuigo.FocusCycleKey), which always works even over a grab-all pane.
- FIX 2 — the REAL hardware cursor. When the pane holds focus the terminal's own cursor blinks at the child's cursor cell; focus the status bar (a non-pane element) and the cursor disappears; open the dialog and it's hidden so it can't poke through.
- FIX 3 — a dialog OVER the pane with clean restore. Ctrl-O to focus the bar, Enter to open a Menu overlay stamped on top of the live shell; pick an item or press Esc and the pane repaints from its Screen with no artifacts.
Run it from the repo root:
go run ./_examples/compositor # embeds bash go run ./_examples/compositor htop # embeds htop (or any program)
Keys:
(pane focused) type / Tab / Shift-Tab / Ctrl-C -> the child shell Ctrl-O -> switch focus (pane <-> bar) (bar focused) Enter -> open the dialog over the pane (dialog open) Up/Down move, Enter select, Esc -> close; pane restored intact
Click to show internal directories.
Click to hide internal directories.