[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: scroll buffer so that current line becomes first visible line
From: |
Tim X |
Subject: |
Re: scroll buffer so that current line becomes first visible line |
Date: |
Fri, 24 Apr 2009 18:35:25 +1000 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.0.92 (gnu/linux) |
Will Willis <will.willis@gmail.com> writes:
> Hello, Is there a command/key binding to scroll my buffer so that the
> current line (the one with my cursor) becomes the first visible line
> in the window. This is akin to C-l, but instead of centering to the
> point, sticking the current line at the top of the window. I'm _not_
> looking to move the point to the first line (M-0 M-r).
>
> I'm not sure how this would work for shorter files, say only a few
> lines long, would a buffer who's length is shorter than the window
> height be able to scroll?
>
maybe of no real help, but....
Emacs 23 (CVS emacs) has re-worked C-l. When you press it the first
time, it centers (old behavior). Press it again and the line is put at
the top of the buffer, hit it a third time and it goes to the
bottom. I've found it really useful.
It may be possible to retro-fit it to emacs 22?
Tim
--
tcross (at) rapttech dot com dot au