shawn bright wrote:
Hello all,

i find myself doing a lot of scrolling. Usually, this is when i am
tracing code to see the flow of a certain thing. I know i have Ctrl-u,
d, f, b for doing a page at a time, but i need to be able to scroll
like a quarter of a page or maybe 20 lines at a time. I know that i
can do 20Ctrl-E or Y to do 20 at a time, but thats kinda long, is
there another way that might be cool, maybe map 20 lines down to some
key i don't use much ?

thanks for any tips.
sk


The answer is contained in your question.

Method I:

        :map <F12> 20<C-E>
        :imap <F12> <C-O>20<C-E>
        :map <S-F12> 20<C-Y>
        :imap <S-F12> <C-O>20<C-Y>

Replace <F12> and <S-F12> by anything that suits you.

Method II:

        :set scroll=20
        " From now on, Ctrl-D and Ctrl-U scroll by 20 lines.
        " Ctrl-F/Ctrl-B (or PgUp/PgDn) still scroll by one page.


Best regards,
Tony.
--
hundred-and-one symptoms of being an internet addict:
150. You find yourself counting emoticons to get to sleep.

Reply via email to