New Opens the file
: Spilt set to horizontal split screen
: Vsplit set to vertical split screen
: Only cancel split screen
>1.ctrl+w, and then immediately a N.
Ctrl+w, another C, is to close the current window
> 2. How to split horizontally?
Ctrl + W, s
Split vertically
Ctrl + W, V
> 3. How do I switch focus?
Ctrl + W, W after one
Ctrl + W, p previous
Ctrl + W, h four Directions
Ctrl + W, I
Ctrl + W, K
Ctrl + W, l
> 4. How do I close other windows?
Ctrl + W, o
More shortcut keys, can be directly queried
: Help Ctrl-w
>5. Loading files
: vs file path/filename opens a file in a new vertical split screen
: SV file path/filename Open file in new horizontal split screen
Turn off split screen
Closes the current window.
Ctrl+w C
Closes the current window, leaving vim if only the last one is left.
CTRL+W Q
Split screen
Splits the currently open file up and down.
Ctrl+w s
Split up and down and open a new file.
: SP filename
Splits the currently open file left and right.
Ctrl+w V
Split left and right, and open a new file.
: VSP filename
Move cursor
VI in the cursor key is H, J, K, L, to switch between the various screens, only need to first click Ctrl+w
Move the cursor to the right screen.
Ctrl+w L
Move the cursor to the left screen.
Ctrl+w h
Move the cursor over the top screen.
Ctrl+w K
Move the cursor to the bottom screen.
Ctrl+w J
Move the cursor to the next screen.
Ctrl+w W
Mobile split Screen
This feature also uses VIM's cursor keys, but it's all capitalized. Of course, if your split screen is very messy and complicated, this feature may have some very strange symptoms.
Move right.
Ctrl+w L
Move left
Ctrl+w H
Move Up
Ctrl+w K
Move Down
Ctrl+w J
Screen size
Here are some of the things that change the size, mostly height, you can use Ctrl+w < or for width, but this may require the latest version to support.
Let all the screens have the same height.
Ctrl+w =
Increase the height.
Ctrl+w +
Reduce height.
Ctrl+w-
Use split-screen display under VI Editor