Vim: Multiple Windows Cheat Sheet

:e filenameEdit another file
:split filenameSplit window and load another file
CTRL-W vVertical split current window
CTRL-W sHorizontal split current window
CTRL-W Arrow UpMove cursor up a window
CTRL-W CTRL-WMove cursor to another window (cycle)
CTRL-W_Maximize current window
CTRL-W=Make all equal size
10 CTRL-W+Increase window size by 10 lines
:vsplit fileVertical split
:sview fileSame as split, but readonly
:hideClose current window
:onlyKeep only this window open
:lsShow current buffers
:b 2Open buffer #2 in this window
:bd[n]Close current bufferIf [n] is given close buffer #n#n can be gathered with :ls.

Leave a Reply

Your email address will not be published. Required fields are marked *