cx-zjtn.5: Ctrl+Cmd+1…9 focuses a pane by number in classic
Summary
Classic could only cycle panes or step one direction at a time. Ctrl+Cmd+1…9 now jumps straight to pane N, matching cmux-next's pane jump keys. Panes number in the tree order Focus Next Pane already walks, and 9 picks the last pane (like Cmd+9 for workspaces). A matched digit is always consumed, so a number past the last pane does nothing instead of reaching the terminal.
Focus Pane 1…9 is a normal numbered shortcut: it shows in Settings > Keyboard Shortcuts, binds via shortcuts.bindings.focusPaneByNumber (any digit stands for the 1…9 family), and is listed on the keyboard-shortcuts docs page and in the schema. It targets the main workspace's panes even while the Dock has focus. Canvas layout is unchanged (it returns false there). Label translated in all 19 catalog locales.
Workspace.focusPane(number:) shares the focus mutation with cycleFocus through a new focusSplitPane helper.
Part of cx-zjtn.5 (keyboard-only cmux).
Testing
tests_v2/test_focus_pane_by_number.py(committed first at 79f004b0892b): three panes (left, top-right, bottom-right), presses Ctrl+Cmd+3/2/1/9 throughdebug.shortcut.simulateand reads the focused pane frompane.list.- Red on a main build (fleet 3cc1207b):
RESULT 1/4. The 1 case passes only because the left pane already had focus. - Green on fleet build 700a6633 of 8e3b8146 (the fix commit):
RESULT 4/4. The test then gained a retry for the socket'spane.listpolling rate limit (e7dca931, test-only); that version produced the 4/4.
- Red on a main build (fleet 3cc1207b):
python3 scripts/verify-local.py: 17/17 passed.swift_file_length_budget.pypasses.
Changelog
Added: Ctrl+Cmd+1…9 focuses split pane 1…9 (9 = last pane)
Proof
Keyboard focus change; the socket test above is the proof.
🤖 Generated with Claude Code
Summary by CodeRabbit
- New Features
- Focus panes 1–8 by their split order and pane 9 to focus the last pane, using configurable number shortcuts. The default shortcut is Control–Command–1 through 9.
- Find and configure the new pane-navigation shortcut in keyboard shortcut settings.