[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: prevent scroll-lock-mode from scrolling?

From: lee
Subject: Re: prevent scroll-lock-mode from scrolling?
Date: Sat, 18 Jun 2016 01:10:55 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

Eli Zaretskii <address@hidden> writes:

>> From: lee <address@hidden>
>> Date: Fri, 17 Jun 2016 03:12:15 +0200
>> is there a way to prevent the point from moving up or down when
>> scroll-lock-mode is enabled and the contents of the buffer have been
>> scrolled so far as for the first or the last line to reach the top or
>> the bottom of the frame, respectively?
>> It pretty much defeats the idea of this mode when the point moves
>> nonetheless after scrolling for a bit, since I would use this mode to
>> keep the point in its very place when scrolling.
> AFAIU, that's exactly the point of this minor mode.  If you don't like
> it, I suggest not to turn on the mode.

Well, what happens when you turn it on and your scrolling reaches the
end of the buffer?

The point moves towards the end of the buffer rather than that the
buffer contents are scrolled up.

>> Thinking of this, is there a kinda complementary mode, or an option, to
>> scroll-lock-mode, which would move the point together with the contents
>> of the buffer when I scroll?
> That's what happens by default, so I don't think I understand what are
> you looking for.  Perhaps consider telling more about the feature you
> want to have.

You must somehow be scrolling very differently from how I scroll.

Or perhaps I shouldn't say "scroll" but "move the point" instead.  When
scroll-lock-mode is enabled and you move the point up or down (C-p or
C-n), the buffer contents are scrolled down or up, respectively, while
the point remains in one place.  Yet when you come close to the top or
the end of the buffer, the point /does/ suddenly move up or down as if
scroll-lock-mode was disabled.  That's what defeats the scroll-lock-mode

I'd even say it's a bug, and that scrolling the buffer contents must
stop when the top/bottom is reached.  Moving the point up or down is
exactly what I /don't/ want when I enable scroll-lock-mode.  Whether the
point should move left or right when scroll-lock-mode is enabled, or if
the buffer contents should be scrolled right or left, should be

GNU Emacs 24.5.1 (x86_64-pc-linux-gnu, X toolkit)
 of 2016-03-18 on heimdali

reply via email to

[Prev in Thread] Current Thread [Next in Thread]