Core Library0.xAPI reference

Choose documentation 1

pr-173

Current version

pr-173
English

Early release libtmux is released, and its APIs may still change between releases. This site's structure and URLs may change too.

MoreLess about this notice

function libtmux-elixir

Window.panes/2

Returns a selection of captured physical panes in numeric pane-ID order.

Source and package
Qualified name
LibTmux.Window.panes/2
Module
LibTmux
Declared in
Window
Package
libtmux
Source
lib/libtmux/entities.ex

Description

Uses the supplied snapshot and validates the window's ID and incarnation. Identity, coverage, empty-selection and no-I/O behavior follow LibTmux.Session.windows/2.

Parameters

Examples

iex> alias LibTmux.{Selection, Snapshot, Window}
iex> rows = %{window: [%{id: "@0"}], pane: [
...> %{id: "%10", window_id: "@0"}, %{id: "%2", window_id: "@0"}]}
iex> {:ok, snapshot} = Snapshot.new(rows,
...> server_instance: "example", captured_from: 0, captured_until: 0,
...> complete: [:pane], fields: %{pane: [:id, :window_id]})
iex> {:ok, window} = Snapshot.fetch(snapshot, :window, "@0")
iex> Window.panes(snapshot, window) |> Enum.map(& &1.id)
["%2", "%10"]
iex> {:ok, pane} = Window.panes(snapshot, window)
...> |> Selection.where(id: "%2") |> Selection.one()
iex> pane.id
"%2"

Recorded calls

source calls
No call edges in the Elixir model.

The Elixir reference records declarations, not calls, so this page shows no callers or callees. That is a limit of the extracted data, not a statement that nothing calls LibTmux.Window.panes/2.

Guides

task material

Pages that discuss panes/2.

Esc
Search in

Type to search.

Reference previewOpen reference