# libtmux::Pane::toggle_zoom

- **Module:** libtmux::Pane
- **Package:** libtmux-cxx
- **Language:** C++
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-cxx/blob/393d4b0ad666f18a6581f1eb281741a75a7503f0/include/libtmux/entities.hpp#L811
- **Page:** https://libtmux.org/en/cxx/latest/reference/libtmux-pane-toggle_zoom/

```
libtmux::Pane::toggle_zoom() -> expected< void, CommandFailure >
```

Toggle whether this pane's window is zoomed onto it — the whole window given over to one pane, full size.

Zoom is window state, which `Window::zoomed()` reads; naming a pane here is how tmux picks which one to give the window to.

Only the zoom-in direction reads this pane: a window already zoomed unzooms on any target, this pane included, and stays on whichever pane it was zoomed onto (measured against raw tmux).
