Window
An immutable physical window with explicit actions, independent of session membership and index.
Source and package
- Qualified name
-
LibTmux. Window - Module
- LibTmux
- Package
- libtmux
- Source
- lib/libtmux/entities.ex
-
Description
What is on here
A Window is a physical window captured in a
LibTmux.Snapshot. Its session index and active state belong to aLibTmux.WindowLink, so one Window can belong to several sessions. Start with these groups:- Finding the window
- Select windows from a captured snapshot, or look one up by its exact ID. Neither contacts tmux. An ID that was not captured returns
{:error, error}with kind:not_found. Turn the window into a reference tied to the server incarnation that supplied it, ready for an action. - SelectBy IDReference
- Looking inside a window
- Read its panes from the snapshot, in numeric pane-ID order and without I/O. An invalid or stale identity, or a relationship the snapshot did not capture, raises
LibTmux.Error. To find the sessions that hold the window, select its links. - Panes
- Renaming
- Rename the window across all its memberships through a Server or a Control connection. A name holds 1..1024 UTF-8 bytes with no control characters, and tmux still normalizes it. The optional
session:reference requires membership in that session; it does not pick a link index. - RenameRaise on failure
- Sharing
- Link this physical window at a specific session index through a Server. Use
LibTmux.WindowLink.unlink/3to remove one membership. - LinkRaise on failure
- Resizing
- Set this physical window's width or height in cells through either transport. Read a fresh snapshot to observe the result.
- ResizeRaise on failure
Members17 members
Collections and queries1
- panes/2 function Returns a selection of captured physical panes in numeric pane-ID order.
Common operations8
- id: String
.t () property Required: building the struct without this key is an error. - name: Lib
Tmux (String.Schema .observed .t ()) property - height: Lib
Tmux (non.Schema .observed _neg ()) property_integer - width: Lib
Tmux (non.Schema .observed _neg ()) property_integer - layout: Lib
Tmux (String.Schema .observed .t ()) property - rename!/4 function Returns
:okwhenrename/4completes; raises API errors orLibTmux.Action.CompletionErrorotherwise. - rename/4 function Renames an exact physical window across all its memberships.
- zoomed: Lib
Tmux (boolean()) property.Schema .observed
Other members8
- kill!/3 function Returns
:okwhenkill/3completes; raises API errors orLibTmux.Action.CompletionErrorotherwise. - kill/3 function Kills an exact window through one-shot execution.
- link!/5 function Returns
:okfor a completed link or raises the action error. - link/5 function Links an exact physical window at the given index in an exact session.
- resize!/3 function Returns
:okfor a completed window resize or raises the action error. - resize/3 function Requests an absolute width, height or both for an exact physical window.
- server_instance: String
.t () property Required: building the struct without this key is an error. - t/0: t() :: %Lib
Tmux { height: Lib.Window Tmux (non.Schema .observed _neg ()), id: String_integer .t (), layout: LibTmux (String.Schema .observed .t ()), name: LibTmux (String.Schema .observed .t ()), server_instance: String.t (), width: LibTmux (non.Schema .observed _neg ()), zoomed: Lib_integer Tmux (boolean()) } typealias A physical window; session index and active-window state belong to a WindowLink..Schema .observed
No members of Window match . The filter searches only this type. Search the whole API.
Order: the accessors that walk the hierarchy, the operations the ports share, then the rest.
In other ports
task equivalence 22 other ports mappedSource-verified mappings for A tmux window. A mapping says these APIs perform the same task. It does not say they share defaults, errors or completion: check each page.
| Port | API | Differs from Elixir |
|---|---|---|
| Elixir | Lib An immutable physical window with explicit actions, independent of session membership and index. | This page |
| Python | libtmux tmux(1) Window [window_manual]. | None recorded in the model |
| Ruby | Lib A physical window on one server, reached through a handle that wraps an
EntityRef. Its index and whether it is current belong to a WindowLink,
so one window can sit in several sessions. Methods take timeout: and
cancel:, and raise CommandError when tmux rejects the command. | None recorded in the model |
| Lua | libtmux | None recorded in the model |
| PowerShell | Lib Read contextual windows from a server or session. | 2 overloads This cmdlet reads shared .NET LibTmux.Window placements. Use -Server for all sessions or -Session for one session. |
| Julia | Lib | 2 overloads WindowSnapshot holds captured physical-window data. WindowLink records a placement in a session; actions use WindowRef. |
| Erlang | #tmux | A physical window can have several session memberships. window_link holds the session-relative index and active flag. |
| Haskell | Lib Detached physical window, independent of its session and index appearances. | Window is a detached physical window, independent of its session placements. WindowLink records each session, index and window binding, and operations take a generation-bound WindowRef. |
| Common Lisp | libtmux: A physical window shared by zero or more captured links. | window is a physical captured window. window-link preserves each session placement. |
| TypeScript | window One window on one tmux server, as a handle rather than a copy of it. | None recorded in the model |
| Rust | window One tmux window, as reached through one session that links it. | None recorded in the model |
| Go | tmux Window is one materialized (session, index, window) winlink record. It is normally returned by Server.Snapshot, Server.Window, or Window.Refresh. A zero Window is not a usable tmux target. | None recorded in the model |
| Java | io One tmux window at one of its positions, as one capture saw it. | readonly |
| Clojure | libtmux Returns the captured window occurrences in a snapshot or session. | Traverses captured window-placement maps without I/O; the window value is a map with an explicit Java reference for effects. |
| Kotlin | io A tmux window at a specific position in a session. | None recorded in the model |
| Scala | io One captured window placement, opaque over the Java handle. Equality includes its session and index, since a window linked into more than one session has more than one placement. Every operation beyond equality is an extension, generated from the operation catalog or handwritten where the catalog marks it WAIT, STREAM or LIFECYCLE. | 2 overloads |
| C# | Lib Represents an immutable window handle and snapshot. | None recorded in the model |
| F# | Lib Identifies window placements and starts queries confined to one window. | This F# module identifies shared .NET LibTmux.Window placements and builds deferred pane queries. Query.list acquires their results from tmux. |
| C++ | libtmux:: One window, as one listing saw it. | None recorded in the model |
| Swift | Window One tmux window, independent of every session that links it. | None recorded in the model |
| OCaml | Libtmux | A global window can have several session placements. Window_link holds the session, index and current flag. |
| Perl | Lib Captured window entity | Physical window identity. WindowLink owns each session/index placement. |
| Raku | Lib Captured physical window; session-relative indices belong to WindowLink. | A physical window may have multiple WindowLink placements, including distinct indexes in one session. |