Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Cursor does not go to top or bottom of window in Gvim 8

Tags:

vim

scroll

Just re-imaged work machine (now with win 10) and reloaded Vim, now Gvim 8. Just noticed this strange behavior in which cursor will not go to the very top or bottom of the page. It will only go as close as 6 lines from the top or bottom (unless at top or bottom of file). Doesn't seem to be scroll related, but more like a margin at top and bottom of page. Aside from that, all works fine but when I do H or L, I want to go all the way to top or bottom, not 6 lines away.

Also, regarding defaults.vim, it does not appear this was in my previous installation, but is now. But, doc says it is used if no .vimrc is found, but I have a .vimrc.

like image 390
bReimers Avatar asked Oct 26 '16 14:10

bReimers


1 Answers

This is caused by the scrolloff option that is set to 5by the new defaults.vim.

See :help 'scrolloff' and :help defaults.vim.

like image 106
romainl Avatar answered Sep 23 '22 15:09

romainl