# tmux.TmuxFilter

- **Module:** tmux
- **Package:** github.com/libtmux/libtmux-go/tmux
- **Language:** Go
- **Kind:** struct
- **Source:** https://github.com/libtmux/libtmux-go/blob/5f808882015a975a65acc7f9da5b3ff0d5cbdc91/tmux/server_buffers.go#L23
- **Page:** https://libtmux.org/reference/go/tmux-tmuxfilter/

TmuxFilter is a raw tmux -f format expression. It is distinct from the generated local filter structs and is evaluated only by tmux. A nil filter omits -f; a nonnil empty filter sends an explicit empty expression.

The expression is tmux's own, so it is written the way tmux's FORMATS
section describes rather than built from Go values:

active := tmux.TmuxFilter("#{==:#{window_active},1}")
windows, err := session.SearchWindows(ctx, &active)

tmux evaluates this while listing. Generated model filters run in Go after
materialization.

revive:disable-next-line:exported TmuxFilter preserves tmux vocabulary beside local model filters.
