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

Server.typed_key_bindings

List key bindings as fields: table, key, command, note and repeat.

Source and package
Qualified name
libtmux::server::Server::typed_key_bindings
Module
server
Declared in
Server
Package
libtmux
Source
crates/libtmux/src/server/keys.rs
pub async fn typed_key_bindings( &self, table: Option<&str> ) -> Result<Vec<KeyBinding>, Error>

Description#

table narrows the listing to one key table. A table with no bindings lists empty, since tmux keeps no empty table to refuse.

Every table is fetched and the narrowing done here. tmux 3.7 through 3.7c send a listing of exactly one binding to the message log instead of printing it, so list-keys -T on a table holding one binding answers with nothing. Across every table, that happens only on a server with a single binding left, which lists none on those releases.

Errors

Returns Error::UnsupportedCapability below tmux 3.7, which has no list-keys -F; Self::key_bindings() reads the bind-key lines those releases print. Returns Error::DecodeListing when a row does not decode, and an error when tmux cannot be reached or refuses the listing.

Parameters

tmux command#

The tmux commands behind typed_key_bindings.

tmux C API#

The C declarations in tmux that implement these commands.

Esc

Type to search.

Reference previewOpen reference