Get or set window position
Example
Normal 0 / 2Command-line 1 / 2Normal 2 / 2Get or set window position.
GUI geometry
- Top-left corner
20, 20 pixels
Command entered · ready to apply
GUI geometry
- Top-left corner
20, 20 pixels
Requests the GUI window's top-left position at x=120, y=80 pixels. This command is unsupported by some GUI/window-manager combinations.
GUI geometry
- Top-left corner
120, 80 pixels
Before & after
Before
GUI geometry
- Top-left corner
20, 20 pixels
After
GUI geometry
- Top-left corner
120, 80 pixels
Subject: :winpos. Documentation-backed illustration; assumes GUI/window manager supporting :winpos and enough screen space to honor the requested coordinates; not replay-verified. Requests the GUI window's top-left position at x=120, y=80 pixels. This command is unsupported by some GUI/window-manager combinations.
notesCursor on line 1, column 1Details & Vim help
Get or set window position. 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 :winp[os] 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.