pane.CapturedLine
Rust
- Python Unavailable
- Ruby Unavailable
- Lua Unavailable
- TypeScript Unavailable
- Rust
- Go Unavailable
- Java Unavailable
- .NET Unavailable
- C++ Unavailable
- Swift Unavailable
- Module
- pane
- Package
- libtmux
- Source
- crates/libtmux/src/pane.rs
-
One line of a capture, with what tmux knows about it.
Built by
Pane::capture_lines. The marks come from the OSC 133 sequences a shell emits around its prompt, so they are present only when the pane's shell emits them.Examples
use libtmux::{CaptureOptions, CapturedLine};let guard = libtmux::test::TestServer::new().await?;let server = guard.server();let session = server.new_session("marked").await?;let pane = session.panes().await?.remove(0);if server.capabilities().await?.tmux_version().has_behavior(&libtmux::since::CAPTURE_LINE_FLAGS) {let lines: Vec<CapturedLine> = pane.capture_lines(CaptureOptions::visible()).await?;assert!(lines.iter().all(|line| !line.starts_output || !line.starts_prompt));}guard.shutdown().await?;
4 declared, 0 inherited
Members
- starts_output attribute Whether a command's output begins on this line.
- starts_prompt attribute Whether a shell prompt begins on this line.
- text attribute The line's text, without the flags tmux prefixed to it.
- wrapped attribute Whether the line continues onto the next row rather than ending.