Vim Recall繁體中文

:tselect and show tag in preview window

:ptselect

Example

Normal 0 / 3

:tselect and show tag in preview window.

Windows

main.vim Active
call Paint()

Prepared tags

1: Paint
a.vim line 1: def Paint()
2: Paint
b.vim line 1: def Paint()
Before & after

Before

Windows

main.vim Active
call Paint()

Prepared tags

1: Paint
a.vim line 1: def Paint()
2: Paint
b.vim line 1: def Paint()

After

Windows

b.vim [Preview]
def Paint()
main.vim Active
call Paint()

Prepared tags

1: Paint
a.vim line 1: def Paint()
2: Paint
b.vim line 1: def Paint()

Subject: :ptselect. Documentation-backed illustration; assumes +quickfix, readable tags and destination files with exactly these two matches; splitbelow unset; previewpopup empty; English messages; the displayed tag list is summarized; not replay-verified. Lists both matching Paint tags and waits for a number; neither destination is chosen yet.

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

:tselect and show tag in 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 :pts[elect] 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.