Vim Recall繁體中文

Edit buffer in the preview window

:pbuffer

Example

Normal 0 / 2

Edit buffer in the preview window.

Windows

main.vim Active
call Paint()
Before & after

Before

Windows

main.vim Active
call Paint()

After

Windows

notes.txt [Preview]
reference notes
main.vim Active
call Paint()

Subject: :pbuffer. Documentation-backed illustration; assumes +quickfix, one ordinary main.vim window and no existing preview, listed loaded buffer number 2 notes.txt, previewpopup empty, nosplitbelow, splitkeep=cursor, enough height for the split, unmapped keys and no interfering callbacks or pending prompts; not replay-verified. Shows buffer 2 in a preview window; main.vim retains focus and its cursor.

Sample buffer
call Paint()
Cursor on line 1, column 1
Details & Vim help

Edit buffer in the preview window. This Ex reference uses the full command name; the alphabetical index omits arguments. Supply the ranges, arguments, flags and prerequisite state documented in the linked help. Press Enter to submit a complete command. The index spelling :pb[uffer] puts the optional abbreviation suffix in square brackets; those brackets are not typed. Availability and exact behavior can depend on Vim build features, options, mappings and editor state; the linked help is authoritative.