Core Library0.xAPI Reference

Choose documentation 3

latest

Current version

latest
English

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

struct libtmux-rs latest

Slot

A typed reference to the object a recorded operation will create.

Source and package
Qualified name
libtmux::plan::Slot
Module
plan
Package
libtmux
Source
crates/libtmux/src/plan.rs
struct plan.Slot

Description#

Returned by Plan::add(). The type parameter is the scope it points at, so a slot for a pane cannot be handed to an operation that wants a window. A slot is only meaningful inside the plan that produced it.

Examples#

use libtmux::plan::{NewWindow, Plan, SendKeys};
use libtmux::SessionId;
let mut plan = Plan::new();
let window = plan.add(NewWindow::new("$0".parse::<SessionId>()?).name("build"));
// A new window owns a first pane, reachable without listing anything.
plan.add(SendKeys::new(window.pane()).text("just check").enter());
Type parameters

Members3#

Common operations1#

  • pane method The first pane of this session's first window.

Other members2#

  • step method The index of the operation that creates this object.
  • window method The first window tmux made with this session.
Esc

Type to search.

Reference previewOpen reference