Prerelease This site documents an alpha of libtmux. Its structure, URLs and APIs are subject to change.

options.OptionSchema

Rust
  • Python Unavailable
  • Ruby Unavailable
  • Lua Unavailable
  • TypeScript Unavailable
  • Rust
  • Go Unavailable
  • Java Unavailable
  • .NET Unavailable
  • C++ Unavailable
  • Swift Unavailable

View as Markdown

Module
options
Package
libtmux
Source
crates/libtmux/src/options.rs
struct options.OptionSchema
structoverload [source]
structoverload [source]
struct options.OptionSchema

What tmux declares about one option.

Examples

use libtmux::{OptionKind, OptionScope, option_schema};
let schema = option_schema("history-limit").expect("a documented option");
assert_eq!(schema.name(), "history-limit");
assert_eq!(schema.kind(), OptionKind::Number);
assert_eq!(schema.scopes(), [OptionScope::Session]);
assert!(schema.accepts(OptionScope::Session));
// An option tmux does not have has no schema, which catches a typo before it
// reaches the server.
assert!(option_schema("history-limits").is_none());

6 declared, 0 inherited

Members

  • choices method Return the words a OptionKind::Choice option accepts, in tmux's order.
  • range method Return the inclusive range a OptionKind::Number option accepts.
  • accepts method Report whether tmux will place a write of this option at scope .
  • kind method Return what kind of value the option holds.
  • name method Return the option's tmux name.
  • scopes method Return every table the option may be written in.
Esc

Type to search.