2

My (n)vim window looks like this:

no padding

Line 91 is the end of the document, and it's flush with the document name at the bottom (essentially the bottom of the screen). How do I "move" that line upwards towards the center like this, as though the document is just shorter than it is?

enter image description here

I don't want to just add a bunch of newlines. Is there any way to pad out the bottom of the document? Thanks!

Sorry about the question tags, I'm not really sure what they should be.

1
  • 2
    Welcome to Vi and Vim! I believe we may have some duplicates of this lying around, but in the meantime, have an answer :) – D. Ben Knoble Jul 27 '20 at 21:40
4

You may be looking for zz, zt, and zb—they center (or move to the top, or to the bottom) the current line on the screen.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.