* Update ssh_backend.md * Update normalize_output_to_unicode_nfc.md * Update strikethrough_position.md * Update underline_position.md * Update underline_thickness.md * Fix lua config docs titles to be formatted as inline code * Mention how suggested alphabet for quick select is choosen * Mention update-status and update-right-status for status_update_interval * Fix docs for all keyassignments to be formatted as inline code * Fix Lua object index titles * Fix titles of `wezterm.*` module index pages * Fix title of `Color` object & `wezterm.color` functions We reduce titles from h2 to h1 because mkdocs defaults the page title to the page file name if no h1 header is found. * Unify title of all object methods * Add index page for Gui events
54 lines
1.2 KiB
Markdown
54 lines
1.2 KiB
Markdown
# `RotatePanes`
|
|
|
|
{{since('20220624-141144-bd1b7c5d')}}
|
|
|
|
Rotates the sequence of panes within the active tab, preserving the sizes based on the tab positions.
|
|
|
|
Panes within a tab have an ordering that follows the creation order of the splits.
|
|
|
|
As an example, if you have three panes created in sequence using horizontal
|
|
splits, their indices from left to right are `0, 1, 2`:
|
|
|
|
```
|
|
|--------|----|----|
|
|
| 0 | 1 | 2 |
|
|
|--------|----|----|
|
|
```
|
|
|
|
If you perform a clockwise rotation on that tab, the indices are rearranged
|
|
so that the panes are now `2, 0, 1`.
|
|
|
|
```
|
|
|--------|----|----|
|
|
| 2 | 0 | 1 |
|
|
|--------|----|----|
|
|
```
|
|
|
|
If you instead perform a counter-clockwise rotation then the indices are rearranged
|
|
so that the panes are now `1, 2, 0`
|
|
|
|
```
|
|
|--------|----|----|
|
|
| 1 | 2 | 0 |
|
|
|--------|----|----|
|
|
```
|
|
|
|
The sizes of original positions are preserved; as you can see from the examples
|
|
above, the left-most pane is still the largest of the panes despite rotating
|
|
the panes withing those placements.
|
|
|
|
```lua
|
|
local act = wezterm.action
|
|
|
|
config.keys = {
|
|
{
|
|
key = 'b',
|
|
mods = 'CTRL',
|
|
action = act.RotatePanes 'CounterClockwise',
|
|
},
|
|
{ key = 'n', mods = 'CTRL', action = act.RotatePanes 'Clockwise' },
|
|
}
|
|
```
|
|
|
|
See also [PaneSelect](PaneSelect.md).
|