Vim's multi-window editing

Source: Internet
Author: User
Tags split

VIM provides the ability to edit multiple windows to simplify complex editing tasks. Vim's multiple windows are not meant to start multiple vim instances on a terminal.

Start multiple window edits

Vim's multiple windows are dynamic, you can open multiple windows when you start editing, add new windows whenever you work, or delete a window.

$ vim-o file1 File2 opens an edit session, which is displayed as a horizontal split window with one file occupying one window.

$ vim-o file1 File2 is the same as above, but is a vertical split between two halves of the window

As shown in the following illustration:

If the screen is not enough to accommodate all the windows, then the first file will occupy most of the window, the remaining window is loaded into the buffer, temporarily can not see, but can still be used.

-O followed by a number n, which is open in the form of a pre-allocated window:

$ vim-o5 file1 file2 will be allocated 5 identical Windows, 3 of which are idle

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.