开发者

Vim: If editing line in window bottom, also show next 4-5 lines

开发者 https://www.devze.com 2023-03-24 14:13 出处:网络
Don\'t exactly know what to search for: If i edit text in vim it sometimes happen that i edit the last visible line. I\'d like also to see the next 5 lines, so i\'m looking for something like an \"edi

Don't exactly know what to search for: If i edit text in vim it sometimes happen that i edit the last visible line. I'd like also to see the next 5 lines, so i'm looking for something like an "edit margin". Or something like: If i edit the third last line vim should scroll down 2 lines automatic. Wo开发者_如何学Gould this be possible?


Yes, you can do this using the scrolloff option.

:set scrolloff=5

This keeps 5 lines visible above/below the cursor.


You're looking for `set scrolloff=5'.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号