Server.split_pane
split_pane(pane => Pane|pane_id, horizontal => boolean?, command => arrayref?, cwd => bytes?, environment => hashref?).
Source and package
-
Description#
Split the targeted pane and return the new captured
LibTmux::Pane. horizontal selects side-by-side placement; false uses tmux's vertical split. command, shell_command, cwd, and environment follow"new_session". Performs I/O; creation/acquisition failures follow"Creation" in LibTmux::X.my $other = $server->split_pane(pane => $pane, horizontal => true, command => ['/bin/cat']);Methods#
tmux command#
The tmux commands behind split_pane.
display-message (daemon identity or target preflight) list-clients (after accepted creation) list-panes -a server scope, cmd_list_panes_server (after accepted creation) list-sessions (after accepted creation) list-windows -a server scope, cmd_list_windows_exec (after accepted creation) split-window tmux C API#
The C declarations in tmux that implement these commands.
cmd_display_message_entry cmd_display_message_exec cmd_list_clients_entry cmd_list_clients_exec cmd_list_panes_entry cmd_list_panes_server cmd_list_sessions_entry cmd_list_sessions_exec cmd_list_windows_entry cmd_list_windows_exec cmd_split_window_entry cmd_split_window_exec Each path starts at a function a command runs, which is degree 1. The degree counts steps from there along the path, and each step is a call or a reference: degree 2 is reached from that function, degree 3 from the next, and so on.
Split a window
- 1
cmd_split_window_exec - references → 2
spawn_pane - calls → 3
window_add_pane - calls → 4
window_pane_create
In other ports#
Split a pane in two
| Language | Equivalent |
|---|---|
| Python | libtmux |
| Ruby | Lib |
| Lua | libtmux |
| Erlang | tmux |
| Haskell | No public Haskell equivalent is implemented; the current modules expose scalar values and version parsing. |
| TypeScript | pane |
| Rust | pane |
| Go | tmux |
| Java | io |
| Clojure | libtmux |
| Kotlin | io |
| Scala | io |
| C# | Lib |
| C++ | no direct pane target; Window.split splits the active pane |
| Swift | Server |
| OCaml | Libtmux |
No equivalent is recorded in PowerShell, Julia, Elixir, Common Lisp or F#.