Skip to content

Initial Panes Implementation (similar to tmux) - #274

Merged
azat merged 10 commits into
mainfrom
tmux
Aug 3, 2026
Merged

Initial Panes Implementation (similar to tmux)#274
azat merged 10 commits into
mainfrom
tmux

Conversation

@azat

@azat azat commented Aug 3, 2026

Copy link
Copy Markdown
Owner

Changes

  • Every view can be opened in a pane
  • Query logs will be opened in a new pane by default (old popup behavior under setting)

Shortcuts

  • Alt+Arrows - navigation
  • Alt+-/=s split pane right/below
  • Ctrl+Arrows - resize
  • Ctrl-x - zoom

Limitations

  • Only unique views can be opened in parallel

Fixes: #164

@azat azat changed the title Panes support (similar to tmux) Initial Panes Implementation (similar to tmux) Aug 3, 2026
azat and others added 2 commits August 4, 2026 00:13
Every provider ended with the same drop_main_view/set_main_view/
focus_name triple; fold it into a single present_view(focus, view)
so the main-view slot has one owner (prepares for pane support).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
present_view() replaces the focused pane via add-new-then-remove-old:
the lone pane cannot be removed from the Mux tree. The replacement view
is constructed before the old one drops, so ViewAction gains an owner
and Drop retains foreign actions instead of clear().

Requires azat-rust/cursive-multiplex branch chdig (Mux::focus_view).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
azat and others added 8 commits August 4, 2026 01:05
split_pane() adds a focusable stub pane and opens the views menu;
the selected view replaces the stub since present_view targets the
focused pane. q quits only from the last pane. Focus/resize/zoom
are Mux-native (Alt+Arrows, Ctrl+Arrows, Ctrl+x).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Action menus listed every live view's actions and duplicate texts
resolved to an arbitrary pane. Filter by ViewAction.owner in the
focused pane subtree; collapse to one pane on host-filter change
(other panes embed the old filter in their queries).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Covers query/table/replica/logger logs; --logs-in-dialog (or the F3
settings checkbox) restores the dialog. TextLog worker channel key
includes the view name (a shared capacity-1 channel drops updates of
concurrent log views). LogViewBase gets take_focus: without it the
pane layout and Mux click-to-focus refuse focus.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…lose)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
remove_id() kept the replaced view and its BackgroundRunner alive
(every ever-opened view kept querying), could focus a view-less split
node (dead-ending all key/mouse input), and after a view replacement
left the root leaf with a stale ancestor chain - the next added pane
(split, logs) landed outside the tree: invisible, but querying.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Separators bordering the focused pane draw in the highlight color
(cursive-multiplex); view titles render bright cyan in the focused
pane and dim cyan elsewhere. A separator shared by two panes cannot
disambiguate them, the title can.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@azat
azat merged commit 015db4c into main Aug 3, 2026
9 checks passed
@azat
azat deleted the tmux branch August 3, 2026 23:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add panes

1 participant