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.

method libtmux-rs latest

Pane.exit_mode

Leave copy mode, or any other mode the pane is in.

Source and package
Qualified name
libtmux::pane::Pane::exit_mode
Module
pane
Declared in
Pane
Package
libtmux
Source
crates/libtmux/src/pane.rs
pub async fn exit_mode(&self) -> Result<(), Error>

Description#

A pane that is in no mode is left alone rather than refused, so this can be called to reach a known state without asking first.

This dispatches copy-mode -q rather than the cancel key, because the key reaches a pane through the copy-mode key table and clock mode and tree mode have none: sending it there is answered "not in a mode" while the pane stays in one. -q is the only exit that covers every mode, including the ones Self::clock_mode() and choose-tree create.

Errors

Returns an error when tmux refuses the command.

tmux command#

The tmux commands behind exit_mode.

tmux C API#

The C declarations in tmux that implement these commands.

Esc

Type to search.

Reference previewOpen reference