From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: lee Newsgroups: gmane.emacs.help Subject: Re: prevent scroll-lock-mode from scrolling? Date: Sat, 18 Jun 2016 01:10:55 +0200 Organization: my virtual residence Message-ID: <8760t7l8cg.fsf@heimdali.yagibdah.de> References: <871t3waaa8.fsf@heimdali.yagibdah.de> <83eg7wcnwj.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1466205128 10279 80.91.229.3 (17 Jun 2016 23:12:08 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 17 Jun 2016 23:12:08 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Jun 18 01:12:03 2016 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1bE2vd-0003QB-IS for geh-help-gnu-emacs@m.gmane.org; Sat, 18 Jun 2016 01:11:57 +0200 Original-Received: from localhost ([::1]:60624 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bE2vZ-0007jg-KP for geh-help-gnu-emacs@m.gmane.org; Fri, 17 Jun 2016 19:11:53 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59882) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bE2un-0007bI-Pn for help-gnu-emacs@gnu.org; Fri, 17 Jun 2016 19:11:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bE2uj-0007AW-Qq for help-gnu-emacs@gnu.org; Fri, 17 Jun 2016 19:11:04 -0400 Original-Received: from acheron.yagibdah.de ([185.55.75.245]:57682) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bE2uj-0007AO-J3 for help-gnu-emacs@gnu.org; Fri, 17 Jun 2016 19:11:01 -0400 Original-Received: from heimdali.yagibdah.de ([192.168.3.20]) by acheron.yagibdah.de with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.85) (envelope-from ) id 1bE2ui-0001GE-1z for help-gnu-emacs@gnu.org; Sat, 18 Jun 2016 01:11:00 +0200 Original-Received: from lee by heimdali.yagibdah.de with local (Exim 4.85) (envelope-from ) id 1bE2uh-0003AA-WF for help-gnu-emacs@gnu.org; Sat, 18 Jun 2016 01:11:00 +0200 In-Reply-To: <83eg7wcnwj.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 17 Jun 2016 09:47:24 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) Mail-Followup-To: help-gnu-emacs@gnu.org X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 185.55.75.245 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:110483 Archived-At: Eli Zaretskii writes: >> From: lee >> 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 entirely. 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 configurable. -- GNU Emacs 24.5.1 (x86_64-pc-linux-gnu, X toolkit) of 2016-03-18 on heimdali