Most of the time, having multiple splits in a window is necessary. But at times its a distraction. There is also a need not to close all other splits in the window; so as, not to lose the context. Below is a neat trick to zoom-in and zoom-out the splits.
noremap Zz <c-w>_ \| <c-w>\|
noremap Zo <c-w>=
The commands won't close any buffers like Ctrl-w + o would.
Explanation of the commands:
Ctrl-w + | Set current window width to N (default: widest possible).
Ctrl-w + _ Set current window height to N (default: highest possible).
Ctrl-w + = Make all windows (almost) equally high and wide.
noremap Zo <c-w>=
The commands won't close any buffers like Ctrl-w + o would.
Explanation of the commands:
Ctrl-w + | Set current window width to N (default: widest possible).
Ctrl-w + _ Set current window height to N (default: highest possible).
Ctrl-w + = Make all windows (almost) equally high and wide.
Resource:
:help window-resize
:help window-resize
Comments
Post a Comment