Sync scroll binding
Example
Normal 0 / 2Command-line 1 / 2Normal 2 / 2Sync scroll binding.
Windows
- left.txt Active
scrollbind on; topline=1- right.txt
scrollbind on; topline=3
Command entered · ready to apply
Windows
- left.txt Active
scrollbind on; topline=1- right.txt
scrollbind on; topline=3
Synchronizes the relative offsets of scroll-bound windows. With the current left view at its top, the right view is brought to its top too; both buffers are unchanged.
Windows
- left.txt Active
scrollbind on; topline=1- right.txt
scrollbind on; topline=1
Before & after
Before
Windows
- left.txt Active
scrollbind on; topline=1- right.txt
scrollbind on; topline=3
After
Windows
- left.txt Active
scrollbind on; topline=1- right.txt
scrollbind on; topline=1
Subject: :syncbind. Documentation-backed illustration; assumes two sufficiently tall scroll-bound buffers, scrollopt includes vertical binding and current left window at topline 1; not replay-verified. Synchronizes the relative offsets of scroll-bound windows. With the current left view at its top, the right view is brought to its top too; both buffers are unchanged.
one
two
three
fourCursor on line 1, column 1Details & Vim help
Sync scroll binding. 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 :sync[bind] 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.