Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

So far, I've figured out swapping splits laterally via CTRL+W x, and that's pretty much it.

How do I move a split anywhere in a viewport that contains multiple vertical and horizontal splits?

How do I create a horizontal split that, say, spans the entire top half of the screen after I have already opened a few vertical splits? (Currently, when I create a new horizontal split in an already-vertically-split viewport, I get a horizontal split in one of the columns.)

Perhaps most vim users prefer tabs over splits, but I really like the latter because I work on a 30" monitor! :-)

share|improve this question
up vote 18 down vote accepted

I suggest you read through the help file for vim windows. The specific sections of that file that apply to your question:

:help opening-window
:help window-moving

Edit: I can only assume this is periodically getting downvotes because I haven't provided specific answers here. The problem is that the original poster asked several questions, and they were broad. The best way to answer all those questions at once is to refer to the Vim documentation, which should always be available wherever Vim is installed.

Also I want to note that I didn't just tell the OP to "RTFM," I provided specific sections of the manual to read, which can be an acceptable answer.

share|improve this answer
RTFM doesn't answer the question. – poindexter Oct 2 '12 at 15:54
@poindexter Could you be more specific about what you don't understand in the documentation? The OP marked my answer as accepted, so it did answer his question. I know the Vim documentation can be a bit terse and hard to understand at first, but it's the best place to go to for answers if you know what to look for. – Heptite Oct 3 '12 at 18:32
we expect SO to be the's easy: google for something, open the SO link and get what you came for, without being redirect to another source. – Danny May 30 '13 at 18:58
@Danny i.e. spoonfeeding. The documentation is great and the answer is there; there's no need to unnecessarily duplicate information. – SpaghettiCat Aug 13 '14 at 8:37
see: "Links to external resources are encouraged, but please add context around the link so your fellow users will have some idea what it is and why it’s there. Always quote the most relevant part of an important link, in case the target site is unreachable or goes permanently offline." – j03w Oct 3 '14 at 4:56

I'm sure the help file covers it, but to move a split to cover the top of the screen, you can do ctrl-w K (with H = left, J = bottom, K = top, L = right).

Note that the letters are uppercase. ctrl-w k will instead move up between splits, etc.

share|improve this answer

You can do:

:to sp


:top split

to do a horizontal window that spans the top of the screen.

share|improve this answer
Thanks both to you and the other poster who gave the first half of the answer. – hakanensari Dec 6 '10 at 22:31
Upvote for answering the question, it'd be nice to see this answer combined with Heptile's. – poindexter Oct 2 '12 at 15:55

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .