Linux applications: Vim Multi-window editing

Source: Internet
Author: User

1. Window segmentation

": Split": Split the cursor window into two windows to display, continuous execution will split out multiple windows

"Ctrl+w W": Jumps to the next window, loops the jump

"Ctrl+w direction (or h,j,k,l)": Jumps to the next window where the direction is drawn

": Close": Close the current window

": Only": Keep the current window only

": New filename": Create a file to split the window

": Nsplit": ' N ' indicates the number of rows displayed in the new window

": Vsplit": Split horizontally, the rest is the same

": vnew filename": Use horizontal split when creating a new file

"Ctrl+w +": Increase the number of rows displayed in the current window (ctrl+w Press ' + ' after you're done)

"Ctrl+w-": Reduce the number of rows displayed in the current window

"Ctrl+w H": Move the current window to the far left

"Ctrl+w J": Move the current window to the bottom

"Ctrl+w K": Move the current window to the top

"Ctrl+w L": Move the current window to the far right

2. Batch processing window

": Qall": Exit all Windows

": Wall": Save All windows

": Wqall": Save and exit all windows

": qall!": Force exit All windows

3. Open more than one window at a time

Command line execution vim-o test1.txt test2.txt test3.txt Open a window for each file

": All": Opens a window for each file in a file list, split horizontally

": Vertical All": ibid., Vertical split

4. tab page

": Tabedit newfile": Create a tab for NewFile and edit NewFile

"GT": Jump between tabs, loop jump

": tabonly": Keep only the current tab, close the Rest of the tab page

Linux applications: Vim Multi-window editing

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.