Browsed by
Category: tools

vim – adjust current line at screen

vim – adjust current line at screen

Here I want to focus on a few keystrokes which help to adjust where your current line appears on your screen in Normal mode.

z[RETURN] redraw screen with current line at top
zz redraw screen with current line at center
z- redraw screen with current line at bottom (as far down as possible)

 

You can display the screen at center even while you are in Insert mode. No need to leave Insert mode, center the screen and reenter Insert mode. That’s especially helpful if you just want to see more context above and beneath your current position.

[ctrl-o]zz run just one command while in Insert mode,
display screen at center and return to Insert mode

 

vim – revisited

vim – revisited

Even though I have been using vim for years now, I realized I should renew and improve what I know about vim in general, especially plugins and stuff. And then there’s a pethora of keyboard shortcuts which can make one’s life a lot easier and more productive.

So there will be a series of blog posts about vim, ranging from the most basic keyboard shortcuts (as a refresher) to more advanced topics like plugins and tuning .vimrc

Read More Read More