From unknown Thu Sep 11 06:21:13 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#23347 <23347@debbugs.gnu.org> To: bug#23347 <23347@debbugs.gnu.org> Subject: Status: 25.0.92; Follow mode scrolling broken -- scrolls only one page Reply-To: bug#23347 <23347@debbugs.gnu.org> Date: Thu, 11 Sep 2025 13:21:13 +0000 retitle 23347 25.0.92; Follow mode scrolling broken -- scrolls only one page reassign 23347 emacs submitter 23347 Anders Lindgren severity 23347 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 23 13:25:18 2016 Received: (at submit) by debbugs.gnu.org; 23 Apr 2016 17:25:18 +0000 Received: from localhost ([127.0.0.1]:44242 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1au1J0-0000bt-Cq for submit@debbugs.gnu.org; Sat, 23 Apr 2016 13:25:18 -0400 Received: from eggs.gnu.org ([208.118.235.92]:49720) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1au1Iz-0000bi-B1 for submit@debbugs.gnu.org; Sat, 23 Apr 2016 13:25:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1au1Is-0005f4-Mc for submit@debbugs.gnu.org; Sat, 23 Apr 2016 13:25:12 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, HTML_MESSAGE,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:59646) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1au1Is-0005ez-K0 for submit@debbugs.gnu.org; Sat, 23 Apr 2016 13:25:10 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40691) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1au1Ir-0006Xk-8g for bug-gnu-emacs@gnu.org; Sat, 23 Apr 2016 13:25:10 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1au1Ip-0005eD-Sq for bug-gnu-emacs@gnu.org; Sat, 23 Apr 2016 13:25:09 -0400 Received: from mail-vk0-x231.google.com ([2607:f8b0:400c:c05::231]:34235) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1au1Ip-0005dr-NJ for bug-gnu-emacs@gnu.org; Sat, 23 Apr 2016 13:25:07 -0400 Received: by mail-vk0-x231.google.com with SMTP id e185so172124444vkb.1 for ; Sat, 23 Apr 2016 10:25:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to; bh=At0mEeSqNInntsiRq9y1yQ9GWxliIqKUSd9TfVXqJ7k=; b=eHtkJGcHgvEhnHXSD3uKXV3zYOfPehTh0Y4mipq2FPusPoYnasES6q5sxAWiAj98af L5AY5fcJfCm3n9jE2Ro1Eo0AlSCBIcePDOnkc/3WNJ1f7RR5Mj1j8eBy1zNJ6ZOuTVqM DCVKsi/5Q/+Dyaakxc0tu5PhYT2YfXwruSspxJBESyTDnVZ0lTGvjCYm6lE63+uHEitA 01Mam6Y6+hhpDMQJpTXuelllEPUFaRnbC3QTmA4XjkPLLReWOc4FBXZfXhtIaNZ6da0b dnUW0Rr09a0z1hGFdjn9lz8zEzqXKoK3oEMJ7BVKO9mKMk5jsYN+VhrBg68usiXwj+Od Xodw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:date:message-id:subject:from:to; bh=At0mEeSqNInntsiRq9y1yQ9GWxliIqKUSd9TfVXqJ7k=; b=K9C/SF0JjwgsEa19CvcQVGQP0+TxZ4PaAT99aZL8oUMHip7t3mE3s4IfZp99f9AqA6 clP1dVHOimQ0bxG4tX18lovt4YDEBvAD981BZlVAyR9iNZXK8ydwCJ0yjpbmQDrrsLbK ckGa7ndF8FhjXefN2zfag9d2Y63VUN2SuO0T+u4L/BQRC10UVGnUFYh+MBi7u14dRuTD 6aUsvsUQzLAhSp9Rvbrjh3ZmZLLFt56nji00km+gad8whqkmEe2ykm4GKUKQIFwRAOnU UoYVBvkWxG/GT+H4wsECXtwFecovI7eRjjBPFomaVgrNzGLOeDXSELGuBXIAH305llE9 NGUQ== X-Gm-Message-State: AOPr4FUFqeioEwfz4ILx5aAYFUImmxq4hjSl5Mi0NHUlz/gjOsiR3xc6t8jksodQgX511/eDzQKK6fJPb1XEDg== MIME-Version: 1.0 X-Received: by 10.176.64.40 with SMTP id h37mr5267841uad.58.1461432306947; Sat, 23 Apr 2016 10:25:06 -0700 (PDT) Received: by 10.31.214.131 with HTTP; Sat, 23 Apr 2016 10:25:06 -0700 (PDT) Date: Sat, 23 Apr 2016 19:25:06 +0200 Message-ID: Subject: 25.0.92; Follow mode scrolling broken -- scrolls only one page From: Anders Lindgren To: bug-gnu-emacs@gnu.org Content-Type: multipart/alternative; boundary=94eb2c12355e84e04d05312a3941 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -2.4 (--) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.4 (--) --94eb2c12355e84e04d05312a3941 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Hi! In Emacs 25.0.92, the command `follow-scroll-up' and `follow-scroll-down' only scroll one page. The intention is that they should scroll as many pages as there are windows in the window group (i.e. the number of windows showing the same buffer in the current frame, when follow-mode is enabled), as was done in Emacs 24. Steps to repeat: emacs -Q C-h t M-x follow-delete-other-windows-and-split RET ;; Page 1 and 2 are visible. C-c . C-v ;; Now, page 2 and 3 are visible. I expect page 3 and 4 to be visible. The idea behind `follow-scroll-up' and `follow-scroll-down' is to scroll away the entire window group at once. For example, if you have six side by side windows, `follow-scroll-up' should go from displaying page 1 .. 6 to 7 .. 12. Currently Emacs 25 go from 1 .. 6 to 2 .. 7. -- Anders Ps. I'm the original author of Follow mode, but I haven't been involved in recent development. In GNU Emacs 25.0.92.6 (x86_64-apple-darwin14.5.0, NS appkit-1348.17 Version 10.10.5 (Build 14F1713)) of 2016-04-10 built on macpro.lan Repository revision: 0e7bcec103073eceecc2621c19e4d290b2d97e8d Windowing system distributor 'Apple', version 10.3.1348 Configured using: 'configure --with-ns --without-dbus' Configured features: NOTIFY ACL ZLIB TOOLKIT_SCROLL_BARS NS Important settings: value of $LC_CTYPE: UTF-8 value of $LANG: en_SE.UTF-8 locale-coding-system: utf-8-unix Major mode: Fundamental Minor modes in effect: follow-mode: t tooltip-mode: t global-eldoc-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t blink-cursor-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Recent messages: For information about GNU Emacs and the GNU system, type C-h C-a. Preparing tutorial ... Resume your last saved tutorial? (y or n) n You can run the command =E2=80=98follow-scroll-up=E2=80=99 with C-c . C-v Load-path shadows: None found. Features: (shadow sort mail-extr emacsbug message dired format-spec rfc822 mml mml-sec password-cache epg epg-config gnus-util mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util help-fns mail-prsvr mail-utils follow tutorial help-mode easymenu cl-loaddefs pcase cl-lib time-date mule-util tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type mwheel ns-win ucs-normalize term/common-win tool-bar dnd fontset image regexp-opt fringe tabulated-list newcomment elisp-mode lisp-mode prog-mode register page menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core frame cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese charscript case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer cl-preloaded nadvice loaddefs button faces cus-face macroexp files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote kqueue cocoa ns multi-tty make-network-process emacs) Memory information: ((conses 16 196924 8312) (symbols 48 19718 0) (miscs 40 48 196) (strings 32 15395 5251) (string-bytes 1 449890) (vectors 16 33084) (vector-slots 8 650906 6707) (floats 8 158 31) (intervals 56 196 0) (buffers 976 12)) --94eb2c12355e84e04d05312a3941 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi!

In Emacs 25.0.92, the co= mmand `follow-scroll-up' and `follow-scroll-down' only scroll one p= age. The intention is that they should scroll as many pages as there are wi= ndows in the window group (i.e. the number of windows showing the same buff= er in the current frame, when follow-mode is enabled), as was done in Emacs= 24.

Steps to repeat:

=C2= =A0 =C2=A0 emacs -Q
=C2=A0 =C2=A0 C-h t
=C2=A0 =C2=A0 M= -x follow-delete-other-windows-and-split RET
=C2=A0 =C2=A0 =C2=A0= ;; Page 1 and 2 are visible.
=C2=A0 =C2=A0 C-c . C-v
= =C2=A0 =C2=A0 =C2=A0 ;; Now, page 2 and 3 are visible.

=
I expect page 3 and 4 to be visible.

The idea= behind `follow-scroll-up' and `follow-scroll-down' is to scroll aw= ay the entire window group at once. For example, if you have six side by si= de windows, `follow-scroll-up' should go from displaying page 1 .. 6 to= 7 .. 12. Currently Emacs 25 go from 1 .. 6 to 2 .. 7.

=
=C2=A0 =C2=A0 -- Anders

Ps. I'm the origi= nal author of Follow mode, but I haven't been involved in recent develo= pment.


In GNU Emacs 25.0.92.6 (x86_= 64-apple-darwin14.5.0, NS appkit-1348.17 Version 10.10.5 (Build 14F1713))
=C2=A0of 2016-04-10 built on macpro.lan
Repository revis= ion: 0e7bcec103073eceecc2621c19e4d290b2d97e8d
Windowing system di= stributor 'Apple', version 10.3.1348
Configured using:
=C2=A0'configure --with-ns --without-dbus'

Configured features:
NOTIFY ACL ZLIB TOOLKIT_SCROLL_BARS= NS

Important settings:
=C2=A0 value of = $LC_CTYPE: UTF-8
=C2=A0 value of $LANG: en_SE.UTF-8
=C2= =A0 locale-coding-system: utf-8-unix

Major mode: F= undamental

Minor modes in effect:
=C2=A0= follow-mode: t
=C2=A0 tooltip-mode: t
=C2=A0 global-el= doc-mode: t
=C2=A0 electric-indent-mode: t
=C2=A0 mouse= -wheel-mode: t
=C2=A0 tool-bar-mode: t
=C2=A0 menu-bar-= mode: t
=C2=A0 file-name-shadow-mode: t
=C2=A0 global-f= ont-lock-mode: t
=C2=A0 blink-cursor-mode: t
=C2=A0 aut= o-composition-mode: t
=C2=A0 auto-encryption-mode: t
= =C2=A0 auto-compression-mode: t
=C2=A0 line-number-mode: t
<= div>=C2=A0 transient-mark-mode: t

Recent messages:=
For information about GNU Emacs and the GNU system, type C-h C-a= .
Preparing tutorial ...
Resume your last saved tutoria= l? (y or n) n
You can run the command =E2=80=98follow-scroll-up= =E2=80=99 with C-c . C-v

Load-path shadows:
<= div>None found.

Features:
(shadow sort m= ail-extr emacsbug message dired format-spec rfc822 mml
mml-sec pa= ssword-cache epg epg-config gnus-util mm-decode mm-bodies
mm-enco= de mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail
rf= c2047 rfc2045 ietf-drums mm-util help-fns mail-prsvr mail-utils follow
tutorial help-mode easymenu cl-loaddefs pcase cl-lib time-date mule-u= til
tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-floa= t-type
mwheel ns-win ucs-normalize term/common-win tool-bar dnd f= ontset image
regexp-opt fringe tabulated-list newcomment elisp-mo= de lisp-mode
prog-mode register page menu-bar rfn-eshadow timer s= elect scroll-bar
mouse jit-lock font-lock syntax facemenu font-co= re frame cl-generic cham
georgian utf-8-lang misc-lang vietnamese= tibetan thai tai-viet lao
korean japanese eucjp-ms cp51932 hebre= w greek romanian slovak czech
european ethiopic indian cyrillic c= hinese charscript case-table epa-hook
jka-cmpr-hook help simple a= bbrev minibuffer cl-preloaded nadvice
loaddefs button faces cus-f= ace macroexp files text-properties overlay
sha1 md5 base64 format= env code-pages mule custom widget
hashtable-print-readable backq= uote kqueue cocoa ns multi-tty
make-network-process emacs)
<= div>
Memory information:
((conses 16 196924 8312)
=C2=A0(symbols 48 19718 0)
=C2=A0(miscs 40 48 196)
=
=C2=A0(strings 32 15395 5251)
=C2=A0(string-bytes 1 449890)<= /div>
=C2=A0(vectors 16 33084)
=C2=A0(vector-slots 8 650906 6= 707)
=C2=A0(floats 8 158 31)
=C2=A0(intervals 56 196 0)=
=C2=A0(buffers 976 12))

--94eb2c12355e84e04d05312a3941-- From debbugs-submit-bounces@debbugs.gnu.org Sun Apr 24 05:00:39 2016 Received: (at 23347) by debbugs.gnu.org; 24 Apr 2016 09:00:39 +0000 Received: from localhost ([127.0.0.1]:44480 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1auFuA-00071J-SZ for submit@debbugs.gnu.org; Sun, 24 Apr 2016 05:00:39 -0400 Received: from mail.muc.de ([193.149.48.3]:59763) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1auFu8-000719-9i for 23347@debbugs.gnu.org; Sun, 24 Apr 2016 05:00:36 -0400 Received: (qmail 87857 invoked by uid 3782); 24 Apr 2016 09:00:35 -0000 Date: 24 Apr 2016 09:00:35 -0000 Message-ID: <20160424090035.87856.qmail@mail.muc.de> From: Alan Mackenzie To: Anders Lindgren Subject: Re: bug#23347: 25.0.92; Follow mode scrolling broken -- scrolls only one page Organization: muc.de e.V. In-Reply-To: X-Newsgroups: gnu.emacs.bug User-Agent: tin/2.3.1-20141224 ("Tallant") (UNIX) (FreeBSD/10.3-RELEASE (amd64)) X-Spam-Score: -1.0 (-) X-Debbugs-Envelope-To: 23347 Cc: 23347@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hello, Anders. In article you wrote: > [-- text/plain, encoding quoted-printable, charset: UTF-8, 106 lines --] > Hi! > In Emacs 25.0.92, the command `follow-scroll-up' and `follow-scroll-down' > only scroll one page. The intention is that they should scroll as many > pages as there are windows in the window group (i.e. the number of windows > showing the same buffer in the current frame, when follow-mode is enabled), > as was done in Emacs 24. It was me who constructed `follow-scroll-up/down' as they currently are. It seemed "obvious" to me that scrolling one page at a time was the Right Thing to do - this enables the user to move, for example, text on the right hand screen to the middle or left, so that she can see it together with either the text above or the text below. Also, three C-v's are easier to type than a third of a C-v. I admit it didn't occur to me that there might be use cases other than my own. What I think we need here is a customisable option. How about `follow-scroll-single-page-flag'? The cleanest default for it would probably be nil, since that better observes the abstraction that the collection of all visible windows should be regarded as a single page. What do you say? > Steps to repeat: > emacs -Q > C-h t > M-x follow-delete-other-windows-and-split RET > ;; Page 1 and 2 are visible. > C-c . C-v > ;; Now, page 2 and 3 are visible. > I expect page 3 and 4 to be visible. > The idea behind `follow-scroll-up' and `follow-scroll-down' is to scroll > away the entire window group at once. For example, if you have six side by > side windows, `follow-scroll-up' should go from displaying page 1 .. 6 to 7 > .. 12. Currently Emacs 25 go from 1 .. 6 to 2 .. 7. > -- Anders > Ps. I'm the original author of Follow mode, but I haven't been involved in > recent development. > In GNU Emacs 25.0.92.6 (x86_64-apple-darwin14.5.0, NS appkit-1348.17 > Version 10.10.5 (Build 14F1713)) > of 2016-04-10 built on macpro.lan > Repository revision: 0e7bcec103073eceecc2621c19e4d290b2d97e8d > Windowing system distributor 'Apple', version 10.3.1348 > Configured using: > 'configure --with-ns --without-dbus' -- Alan Mackenzie (Nuremberg, Germany). From debbugs-submit-bounces@debbugs.gnu.org Sun Apr 24 08:36:34 2016 Received: (at 23347) by debbugs.gnu.org; 24 Apr 2016 12:36:34 +0000 Received: from localhost ([127.0.0.1]:44578 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1auJH8-0006yD-1w for submit@debbugs.gnu.org; Sun, 24 Apr 2016 08:36:34 -0400 Received: from mail-vk0-f52.google.com ([209.85.213.52]:33365) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1auJH6-0006y0-KQ for 23347@debbugs.gnu.org; Sun, 24 Apr 2016 08:36:32 -0400 Received: by mail-vk0-f52.google.com with SMTP id n62so186287481vkb.0 for <23347@debbugs.gnu.org>; Sun, 24 Apr 2016 05:36:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc; bh=25rPZGetJJwOqc0mAfeF80+MgZJyDBKEe0a/s8tWGO0=; b=zHlYryxr1PyA1+xqwrIzHPyHSxjQA+HF7VhOrc9xX5vuZk5+iNpYAa/nPNf7eAXR4q 3PdzAtfZE11mbaPS5N3Ni9/S5WSC3wKKmW9DqOd1UhKn29dJ9xq9N4/fMy1rJzZBuDs7 TwgzLTLnAzGwKcVj90cu5iXHviS2nXKZPxv2Ghmb8T0TxqROnk8JHgBJq6HP2nb3eR+z 6FIU9Zbvp8DjeeAB9UKOP0bXN/7KgN2F9j0jiJOcQ3BZvHrOxoAbJFPhw53v0MtzUY1P UFTiDHJBBCtM2MWIoW7RfyYkXhIXQeSRkOphw/mF7wgtaoNRAUpolWe+S72qxVeoKLuE 2UGQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc; bh=25rPZGetJJwOqc0mAfeF80+MgZJyDBKEe0a/s8tWGO0=; b=EbqyUIsHqQyz1RHsgiUp3NgJm7Bj2eB0fqD8kpYz/oBsX+iUyHrIcDrz4nzSrhbX7O tFll2wRRLB0kjzLUM/LaR2IimWcexapkzEPljKxhBAnJSAS/gP2MS8McJBSt5NrWDgpw jew2/rxTlZuWIjXCdiSZQC8Qint3MKTF/DfYhXvg+FdU0m4Qia5hUZvlfiJ4ccFrQMXN NJi5t0MYje8RqPqgHtb3n4ADV6zq0bqMPkYKJ4849NGg7RxiAup5Q+okAXd4d+s81JtG Urr/jyCEZGiZEWlS2ka0TmxgTWOs31r9sv3pr7LPJ3/KYXsPnpdsT0oVv/dBLyeJmChQ dveg== X-Gm-Message-State: AOPr4FX6w69McoO2sEkyOf0RSTOvTStgyp7PeaOkAeNgcqSYPj9DHHi7jlOP7TDUEv6s3wuWCkYSIhacw58eRA== MIME-Version: 1.0 X-Received: by 10.176.3.176 with SMTP id 45mr12382892uau.60.1461501387126; Sun, 24 Apr 2016 05:36:27 -0700 (PDT) Received: by 10.31.214.131 with HTTP; Sun, 24 Apr 2016 05:36:27 -0700 (PDT) In-Reply-To: <20160424090035.87856.qmail@mail.muc.de> References: <20160424090035.87856.qmail@mail.muc.de> Date: Sun, 24 Apr 2016 14:36:27 +0200 Message-ID: Subject: Re: bug#23347: 25.0.92; Follow mode scrolling broken -- scrolls only one page From: Anders Lindgren To: Alan Mackenzie Content-Type: multipart/alternative; boundary=94eb2c09daf004bd5305313a4fcf X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 23347 Cc: 23347@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) --94eb2c09daf004bd5305313a4fcf Content-Type: text/plain; charset=UTF-8 Hi! The normal `scroll-up-command' and `scroll-down-command' (typically bound to C-v and M-v) can scroll a page at a time, there is no need for a Follow mode-specific command for that, as the normal Follow mode machinery can reposition the other windows. (The only difference is that when using C-v the original window is still selected, whereas with the new follow-scroll-up command the windows where the original point ends up is selected.) I admit it didn't occur to me that there might be use cases other than my > own. What I think we need here is a customisable option. How about > `follow-scroll-single-page-flag'? The cleanest default for it would > probably be nil, since that better observes the abstraction that the > collection of all visible windows should be regarded as a single page. > A cleaner solution would be to define two sets of functions, e.g. follow-scroll-up-one-page. Many users might want to use both kind of scrolling (I use both C-v and C-c . C-v several time every day, depending on how I would like to scroll the display). With two sets of functions it's easier to do this. (Also, it's easier to write documentation for a function designed to do one thing.) -- Anders --94eb2c09daf004bd5305313a4fcf Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi!

The normal `scroll-up-command= ' and `scroll-down-command' (typically bound to C-v and M-v) can sc= roll a page at a time, there is no need for a Follow mode-specific command = for that, as the normal Follow mode machinery can reposition the other wind= ows. (The only difference is that when using C-v the original window is sti= ll selected, whereas with the new follow-scroll-up command the windows wher= e the original point ends up is selected.)


I admit it didn't occur to me that there might be use cases othe= r than my
own.=C2=A0 What I think we need here is a customisable option.=C2=A0 How ab= out
`follow-scroll-single-page-flag'?=C2=A0 The cleanest default for it wou= ld
probably be nil, since that better observes the abstraction that the
collection of all visible windows should be regarded as a single page.
<= /blockquote>

A cleaner solution would be to define two s= ets of functions, e.g. follow-scroll-up-one-page. Many users might want to = use both kind of scrolling (I use both C-v and C-c . C-v several time every= day, depending on how I would like to scroll the display). With two sets o= f functions it's easier to do this. (Also, it's easier to write doc= umentation for a function designed to do one thing.)

=C2=A0 =C2=A0 -- Anders

--94eb2c09daf004bd5305313a4fcf-- From debbugs-submit-bounces@debbugs.gnu.org Sun Apr 24 10:26:53 2016 Received: (at 23347) by debbugs.gnu.org; 24 Apr 2016 14:26:54 +0000 Received: from localhost ([127.0.0.1]:45119 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1auKzt-0002xr-OQ for submit@debbugs.gnu.org; Sun, 24 Apr 2016 10:26:53 -0400 Received: from mail.muc.de ([193.149.48.3]:30307) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1auKzr-0002xi-Pe for 23347@debbugs.gnu.org; Sun, 24 Apr 2016 10:26:52 -0400 Received: (qmail 66434 invoked by uid 3782); 24 Apr 2016 14:26:50 -0000 Received: from acm.muc.de (p548A445C.dip0.t-ipconnect.de [84.138.68.92]) by colin.muc.de (tmda-ofmipd) with ESMTP; Sun, 24 Apr 2016 16:26:48 +0200 Received: (qmail 5700 invoked by uid 1000); 24 Apr 2016 14:23:13 -0000 Date: Sun, 24 Apr 2016 14:23:13 +0000 To: Anders Lindgren Subject: Re: bug#23347: 25.0.92; Follow mode scrolling broken -- scrolls only one page Message-ID: <20160424142313.GB3517@acm.fritz.box> References: <20160424090035.87856.qmail@mail.muc.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) X-Delivery-Agent: TMDA/1.1.12 (Macallan) From: Alan Mackenzie X-Primary-Address: acm@muc.de X-Spam-Score: -1.0 (-) X-Debbugs-Envelope-To: 23347 Cc: 23347@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hello, Anders. On Sun, Apr 24, 2016 at 02:36:27PM +0200, Anders Lindgren wrote: > Hi! > The normal `scroll-up-command' and `scroll-down-command' (typically bound > to C-v and M-v) can scroll a page at a time, there is no need for a Follow > mode-specific command for that, as the normal Follow mode machinery can > reposition the other windows. (The only difference is that when using C-v > the original window is still selected, whereas with the new > follow-scroll-up command the windows where the original point ends up is > selected.) Indeed. This is a difference important enough to have a command in follow.el which keeps point at the same buffer position it started with. > > I admit it didn't occur to me that there might be use cases other > > than my own. What I think we need here is a customisable option. > > How about `follow-scroll-single-page-flag'? The cleanest default > > for it would probably be nil, since that better observes the > > abstraction that the collection of all visible windows should be > > regarded as a single page. > A cleaner solution would be to define two sets of functions, e.g. > follow-scroll-up-one-page. OK. I'm happy enought with that. I'm not sure that's a good name, though - the "page" bit could easily get confused with the region in a buffer between two ^L characters. Maybe follow-scroll-up-window would be better. What do you think? > Many users might want to use both kind of scrolling (I use both C-v > and C-c . C-v several time every day, depending on how I would like to > scroll the display). With two sets of functions it's easier to do > this. (Also, it's easier to write documentation for a function > designed to do one thing.) For me, C-c . C-v is too tedious to type, so I've just bound and to `follow-scroll-down/up'. I use them many times per day. Another possibility would be to use a C-u prefix argument to indicate N windows as opposed to 1. No, I don't think that's a good idea, either. Anyway, here is what I think we can agree on: 1. `follow-scroll-up/down' should scroll by N windows. 2. There need to be commands in follow.el that scroll by 1 window as is done by the current `follow-scroll-up/down'. You have suggested the name `follow-scroll-up/down-one-page'. I have countered with `follow-scroll-up/down-window'. If we can agree, I'm willing to amend follow.el. I think it's probably too late for this fix to make it into Emacs 25.1, though. > -- Anders -- Alan Mackenzie (Nuremberg, Germany). From debbugs-submit-bounces@debbugs.gnu.org Sun Apr 24 11:38:05 2016 Received: (at 23347) by debbugs.gnu.org; 24 Apr 2016 15:38:05 +0000 Received: from localhost ([127.0.0.1]:45160 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1auM6n-0007uG-4c for submit@debbugs.gnu.org; Sun, 24 Apr 2016 11:38:05 -0400 Received: from mail-vk0-f52.google.com ([209.85.213.52]:35658) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1auM6k-0007tX-MR for 23347@debbugs.gnu.org; Sun, 24 Apr 2016 11:38:03 -0400 Received: by mail-vk0-f52.google.com with SMTP id t129so189068890vkg.2 for <23347@debbugs.gnu.org>; Sun, 24 Apr 2016 08:38:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc; bh=MAEkOak3HfkuxVhrLE7RqVT7DcwvZzyZr2SvYHBH7hg=; b=Yccj1scBzrDjicS5kQP0o++sVI8XtxH0nAPF1YZRWA4AsrSIWH6ClMmFpJrQyWSvVF GeC/MHhAy7mX5G7xdmtbw9Z6jW5g4n09earPxHHxj9BqtOtqeGs6/jC8/Qj2TPyi16GY xHNbqXdSOyEq+wHus6L7xO7Ayuc/D+oyK8skaTeZ4QFEWSFOlhXo8Lrw8X3ZtwJNmv7f qU4m/GLUYotb0FN5cPYEwDB1MwmFZncQwZS1R4/4sQuwp7AmP1B66gYmcO6apmB84bkk Ta/gpdsIrRCsC8N0fh6oUmIYEfwvq3fMvwZIf7o9EkuL8ohP92PDkT0EokPoWDk/Xmxs ExLg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc; bh=MAEkOak3HfkuxVhrLE7RqVT7DcwvZzyZr2SvYHBH7hg=; b=I8IqZwgThmzfqHfS8eQWXJ+zHkA+os+ytFavz8uxbuq4fCEVuyS4/GBMVJG+5sEEwA KFzE+8Fa3FdR5JSDVYNjZZOc9mrORRvdtKGQte/toF5rJMsUz5KjMqJnOM84Brm4I8B1 gV+Tr1MexaB03raZPmql/sU4PNTjDdb47cnJefKFiC5RH0x+mVbAFnvH9ZsLGKZSIMOR a4l/iUMu+3AROay+Opuhksnz8EfBe9Eu1DL+Aoc68aNarNb8g7XmfcQjRqH94YeMcvhn R//aZ+lLrXK/XvuaWymY7qmanV3nlWFPC0CCAPRDSKli4Ew5YW8ld1dLMXAYVJlSQRM7 bjyw== X-Gm-Message-State: AOPr4FWfThi6wlUpoqXUo7qU8z9lB5ZOMsQ7ikUSuWwfurDHEZaY3X9tp/yREQ9WN3cePHgnVHZbEbOvHjAC8g== MIME-Version: 1.0 X-Received: by 10.159.35.136 with SMTP id 8mr14389596uao.47.1461512277193; Sun, 24 Apr 2016 08:37:57 -0700 (PDT) Received: by 10.31.214.131 with HTTP; Sun, 24 Apr 2016 08:37:57 -0700 (PDT) In-Reply-To: <20160424142313.GB3517@acm.fritz.box> References: <20160424090035.87856.qmail@mail.muc.de> <20160424142313.GB3517@acm.fritz.box> Date: Sun, 24 Apr 2016 17:37:57 +0200 Message-ID: Subject: Re: bug#23347: 25.0.92; Follow mode scrolling broken -- scrolls only one page From: Anders Lindgren To: Alan Mackenzie Content-Type: multipart/alternative; boundary=94eb2c0416b41dfd0a05313cd8e7 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 23347 Cc: 23347@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) --94eb2c0416b41dfd0a05313cd8e7 Content-Type: text/plain; charset=UTF-8 Hi! > > The normal `scroll-up-command' and `scroll-down-command' (typically bound > > to C-v and M-v) can scroll a page at a time, there is no need for a > Follow > > mode-specific command for that, as the normal Follow mode machinery can > > reposition the other windows. (The only difference is that when using C-v > > the original window is still selected, whereas with the new > > follow-scroll-up command the windows where the original point ends up is > > selected.) > > Indeed. This is a difference important enough to have a command in > follow.el which keeps point at the same buffer position it started with. > Agreed. All three scroll commands (non-follow-mode scroll, scroll one page, and scroll N pages) are useful. > A cleaner solution would be to define two sets of functions, e.g. > > follow-scroll-up-one-page. > > OK. I'm happy enought with that. > > I'm not sure that's a good name, though - the "page" bit could easily > get confused with the region in a buffer between two ^L characters. > > Maybe follow-scroll-up-window would be better. What do you think? > Yes, I agree, `page' isn't a good choice. What about `follow-scroll-up-keep-point'? That way it would be clear what the difference is between it and the normal scroll command. If I would have designed Follow mode today, I probably would have used your name, `follow-scroll-up-window', and named the N-page scroll `follow-scroll-up-window-group'. > > Many users might want to use both kind of scrolling (I use both C-v > > and C-c . C-v several time every day, depending on how I would like to > > scroll the display). With two sets of functions it's easier to do > > this. (Also, it's easier to write documentation for a function > > designed to do one thing.) > > For me, C-c . C-v is too tedious to type, so I've just bound > and to `follow-scroll-down/up'. I use them many times per > day. > I've remapped them to C-c C-v and C-c v, that way I can scroll a window down a single page using C-v and the entire display using C-c C-v. Of course, this isn't in a part of a keymap available to minor modes, so it's nothing we can make official. Another possibility would be to use a C-u prefix argument to indicate N > windows as opposed to 1. No, I don't think that's a good idea, either. > No, too cumbersome. Anyway, here is what I think we can agree on: > 1. `follow-scroll-up/down' should scroll by N windows. > 2. There need to be commands in follow.el that scroll by 1 window as is > done by the current `follow-scroll-up/down'. You have suggested the > name `follow-scroll-up/down-one-page'. I have countered with > `follow-scroll-up/down-window'. > > If we can agree, I'm willing to amend follow.el. I think it's probably > too late for this fix to make it into Emacs 25.1, though. > Well, give it a try. Feel free to pick a suitable name. If we come up with a clean solution quickly John might accept it. -- Anders --94eb2c0416b41dfd0a05313cd8e7 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi!
=C2=A0
> The normal `scroll-up-command' and `scroll-down-command' (typi= cally bound
> to C-v and M-v) can scroll a page at a time, there is no need for a Fo= llow
> mode-specific command for that, as the normal Follow mode machinery ca= n
> reposition the other windows. (The only difference is that when using = C-v
> the original window is still selected, whereas with the new
> follow-scroll-up command the windows where the original point ends up = is
> selected.)

Indeed.=C2=A0 This is a difference important enough to have a comman= d in
follow.el which keeps point at the same buffer position it started with.

Agreed. All three scroll commands (non-fo= llow-mode scroll, scroll one page, and scroll N pages) are useful.

> A cleaner = solution would be to define two sets of functions, e.g.
> follow-scroll-up-one-page.

OK.=C2=A0 I'm happy enought with that.

I'm not sure that's a good name, though - the "page" bit = could easily
get confused with the region in a buffer between two ^L characters.

Maybe follow-scroll-up-window would be better.=C2=A0 What do you think?
=

Yes, I agree, `page' isn't a good = choice.

What about `follow-scroll-up-keep-point= 9;? That way it would be clear what the difference is between it and the no= rmal scroll command.

If I would have designed Foll= ow mode today, I probably would have used your name, `follow-scroll-up-wind= ow', and named the N-page scroll `follow-scroll-up-window-group'.

=C2=A0
> Many users might want to use both kind of scrolling (I use bo= th C-v
> and C-c . C-v several time every day, depending on how I would like to=
> scroll the display). With two sets of functions it's easier to do<= br> > this. (Also, it's easier to write documentation for a function
> designed to do one thing.)

For me, C-c . C-v is too tedious to type, so I've just bound <= ;PageUp>
and <PageDown> to `follow-scroll-down/up'.=C2=A0 I use them many = times per
day.

I've remapped them to C-c C-v = and C-c v, that way I can scroll a window down a single page using C-v and = the entire display using C-c C-v. Of course, this isn't in a part of a = keymap available to minor modes, so it's nothing we can make official.<= /div>


Another = possibility would be to use a C-u prefix argument to indicate N
windows as opposed to 1.=C2=A0 No, I don't think that's a good idea= , either.

No, too cumbersome.
=C2=A0

Anyway, here is = what I think we can agree on:
1. `follow-scroll-up/down' should scroll by N windows.
2. There need to be commands in follow.el that scroll by 1 window as is
=C2=A0 done by the current `follow-scroll-up/down'.=C2=A0 You have sugg= ested the
=C2=A0 name `follow-scroll-up/down-one-page'.=C2=A0 I have countered wi= th
=C2=A0 `follow-scroll-up/down-window'.

If we can agree, I'm willing to amend follow.el.=C2=A0 I think it's= probably
too late for this fix to make it into Emacs 25.1, though.
<= div>
Well, give it a try. Feel free to pick a suitable name. = If we come up with a clean solution quickly John might accept it.
=C2=A0
=C2=A0 =C2=A0 -- Anders

<= /div> --94eb2c0416b41dfd0a05313cd8e7-- From debbugs-submit-bounces@debbugs.gnu.org Tue Apr 26 07:59:31 2016 Received: (at 23347) by debbugs.gnu.org; 26 Apr 2016 11:59:31 +0000 Received: from localhost ([127.0.0.1]:47551 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1av1eN-0003HF-1t for submit@debbugs.gnu.org; Tue, 26 Apr 2016 07:59:31 -0400 Received: from mail.muc.de ([193.149.48.3]:39667) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1av1eL-0003H6-69 for 23347@debbugs.gnu.org; Tue, 26 Apr 2016 07:59:29 -0400 Received: (qmail 17015 invoked by uid 3782); 26 Apr 2016 11:59:27 -0000 Received: from acm.muc.de (p548A4B35.dip0.t-ipconnect.de [84.138.75.53]) by colin.muc.de (tmda-ofmipd) with ESMTP; Tue, 26 Apr 2016 13:59:26 +0200 Received: (qmail 4389 invoked by uid 1000); 26 Apr 2016 11:51:08 -0000 Date: Tue, 26 Apr 2016 11:51:08 +0000 To: Anders Lindgren Subject: Re: bug#23347: 25.0.92; Follow mode scrolling broken -- scrolls only one page Message-ID: <20160426115108.GC3033@acm.fritz.box> References: <20160424090035.87856.qmail@mail.muc.de> <20160424142313.GB3517@acm.fritz.box> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) X-Delivery-Agent: TMDA/1.1.12 (Macallan) From: Alan Mackenzie X-Primary-Address: acm@muc.de X-Spam-Score: -1.0 (-) X-Debbugs-Envelope-To: 23347 Cc: 23347@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hello, Anders. On Sun, Apr 24, 2016 at 05:37:57PM +0200, Anders Lindgren wrote: > Hi! > Agreed. All three scroll commands (non-follow-mode scroll, scroll one page, > and scroll N pages) are useful. [ .... ] > Yes, I agree, `page' isn't a good choice. > What about `follow-scroll-up-keep-point'? That way it would be clear what > the difference is between it and the normal scroll command. > If I would have designed Follow mode today, I probably would have used your > name, `follow-scroll-up-window', and named the N-page scroll > `follow-scroll-up-window-group'. I've just used `follow-scroll-up-window' and `follow-scroll-down-window'. At least, for now. [ .... ] > Anyway, here is what I think we can agree on: > > 1. `follow-scroll-up/down' should scroll by N windows. > > 2. There need to be commands in follow.el that scroll by 1 window as is > > done by the current `follow-scroll-up/down'. You have suggested the > > name `follow-scroll-up/down-one-page'. I have countered with > > `follow-scroll-up/down-window'. > > If we can agree, I'm willing to amend follow.el. I think it's probably > > too late for this fix to make it into Emacs 25.1, though. > > > Well, give it a try. Feel free to pick a suitable name. If we come up with > a clean solution quickly John might accept it. OK. I had one or two minor problems with follow-scroll-up/down with a non-nil ARG. In the end, I just extracted functionality from follow-scroll-up/down-window into separate functions, and called those from all four scrolling functions. Anyway, here is the patch I've come up with. Could you review it and test it, please. Thanks! diff --git a/lisp/follow.el b/lisp/follow.el index 5801f79..3e23247 100644 --- a/lisp/follow.el +++ b/lisp/follow.el @@ -532,6 +532,80 @@ follow-get-scrolled-point ;; position... (This would also be corrected if we would have had a ;; good redisplay abstraction.) +(defun follow-scroll-up-arg (arg) + "Scroll the text in a follow mode window chain up by ARG lines. +If ARG is nil, scroll the size of the current window. + +This is an internal function for `follow-scroll-up' and +`follow-scroll-up-window'." + (let ((opoint (point)) (owin (selected-window))) + (while + ;; If we are too near EOB, try scrolling the previous window. + (condition-case nil (progn (scroll-up arg) nil) + (end-of-buffer + (condition-case nil (progn (follow-previous-window) t) + (error + (select-window owin) + (goto-char opoint) + (signal 'end-of-buffer nil)))))) + (unless (and scroll-preserve-screen-position + (get this-command 'scroll-command)) + (goto-char opoint)) + (setq follow-fixed-window t))) + +(defun follow-scroll-down-arg (arg) + "Scroll the text in a follow mode window chain down by ARG lines. +If ARG is nil, scroll the size of the current window. + +This is an internal function for `follow-scroll-down' and +`follow-scroll-down-window'." + (let ((opoint (point))) + (scroll-down arg) + (unless (and scroll-preserve-screen-position + (get this-command 'scroll-command)) + (goto-char opoint)) + (setq follow-fixed-window t))) + +;;;###autoload +(defun follow-scroll-up-window (&optional arg) + "Scroll text in a Follow mode window up by that window's size. +The other windows in the window chain will scroll synchronously. + +If called with no ARG, the `next-screen-context-lines' last lines of +the window will be visible after the scroll. + +If called with an argument, scroll ARG lines up. +Negative ARG means scroll downward. + +Works like `scroll-up' when not in Follow mode." + (interactive "P") + (cond ((not follow-mode) + (scroll-up arg)) + ((eq arg '-) + (follow-scroll-down-window)) + (t (follow-scroll-up-arg arg)))) +(put 'follow-scroll-up-window 'scroll-command t) + +;;;###autoload +(defun follow-scroll-down-window (&optional arg) + "Scroll text in a Follow mode window down by that window's size. +The other windows in the window chain will scroll synchronously. + +If called with no ARG, the `next-screen-context-lines' top lines of +the window in the chain will be visible after the scroll. + +If called with an argument, scroll ARG lines down. +Negative ARG means scroll upward. + +Works like `scroll-down' when not in Follow mode." + (interactive "P") + (cond ((not follow-mode) + (scroll-down arg)) + ((eq arg '-) + (follow-scroll-up-window)) + (t (follow-scroll-down-arg arg)))) +(put 'follow-scroll-down-window 'scroll-command t) + ;;;###autoload (defun follow-scroll-up (&optional arg) "Scroll text in a Follow mode window chain up. @@ -546,23 +620,18 @@ follow-scroll-up (interactive "P") (cond ((not follow-mode) (scroll-up arg)) - ((eq arg '-) - (follow-scroll-down)) - (t - (let ((opoint (point)) (owin (selected-window))) - (while - ;; If we are too near EOB, try scrolling the previous window. - (condition-case nil (progn (scroll-up arg) nil) - (end-of-buffer - (condition-case nil (progn (follow-previous-window) t) - (error - (select-window owin) - (goto-char opoint) - (signal 'end-of-buffer nil)))))) - (unless (and scroll-preserve-screen-position - (get this-command 'scroll-command)) - (goto-char opoint)) - (setq follow-fixed-window t))))) + (arg (follow-scroll-up-arg arg)) + (t + (let* ((windows (follow-all-followers)) + (end (window-end (car (reverse windows))))) + (if (eq end (point-max)) + (signal 'end-of-buffer nil) + (select-window (car windows)) + ;; `window-end' might return nil. + (if end + (goto-char end)) + (vertical-motion (- next-screen-context-lines)) + (set-window-start (car windows) (point))))))) (put 'follow-scroll-up 'scroll-command t) ;;;###autoload @@ -579,15 +648,22 @@ follow-scroll-down (interactive "P") (cond ((not follow-mode) (scroll-down arg)) - ((eq arg '-) - (follow-scroll-up)) - (t - (let ((opoint (point))) - (scroll-down arg) - (unless (and scroll-preserve-screen-position - (get this-command 'scroll-command)) - (goto-char opoint)) - (setq follow-fixed-window t))))) + (arg (follow-scroll-down-arg arg)) + (t + (let* ((windows (follow-all-followers)) + (win (car (reverse windows))) + (start (window-start (car windows)))) + (if (eq start (point-min)) + (signal 'beginning-of-buffer nil) + (select-window win) + (goto-char start) + (vertical-motion (- (- (window-height win) + (if header-line-format 2 1) + next-screen-context-lines))) + (set-window-start win (point)) + (goto-char start) + (vertical-motion (- next-screen-context-lines 1)) + (setq follow-internal-force-redisplay t)))))) (put 'follow-scroll-down 'scroll-command t) (declare-function comint-adjust-point "comint" (window)) > -- Anders -- Alan Mackenzie (Nuremberg, Germany). From debbugs-submit-bounces@debbugs.gnu.org Tue Apr 26 09:08:38 2016 Received: (at 23347) by debbugs.gnu.org; 26 Apr 2016 13:08:38 +0000 Received: from localhost ([127.0.0.1]:47578 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1av2jG-00055b-3T for submit@debbugs.gnu.org; Tue, 26 Apr 2016 09:08:38 -0400 Received: from mail-vk0-f48.google.com ([209.85.213.48]:33120) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1av2jE-00055M-Ko for 23347@debbugs.gnu.org; Tue, 26 Apr 2016 09:08:37 -0400 Received: by mail-vk0-f48.google.com with SMTP id o133so15727141vka.0 for <23347@debbugs.gnu.org>; Tue, 26 Apr 2016 06:08:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc; bh=cfzM11zz6RcKEwquX+yjwR7ryGQYvC3Ymthn8aPbdG0=; b=i3eCLD7Ee+zO5Sn+OL97MxhZpk+O7UQpHDBb02JjERrYI7yEBXfQUSh09nCK8/Iasy QHACqHsWcoTc/44izXRd/doqxxq3cQcIbcJQ8l3ThCM8UgbCCLP1LGDBeQYhmQ0etP6/ T2gBmLE2YnficjGEhltbz6nMMakKEZvSPiZKWOjaDVOIRTllF+Fx/WRcYGlgom9cm1zQ ZCnS4hIsTuqYN05cBn4FmnWxPQtYtHsgX0/C/Vvvn64ulOWtL9Q9BO/gw8/gQ5Ibmthn jvKKA6v2KStdUOC14yBmWHG4LYYgKJk/CKaoXtYpPvJzRypMn3GOz9gnYt1abPBAw1K3 tgFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc; bh=cfzM11zz6RcKEwquX+yjwR7ryGQYvC3Ymthn8aPbdG0=; b=FNq2HqHok8Sd9AEXweOvVGQsHbvtfSS/s3mpgOyZ0rrOEyCosC7RaeajO8Smr2NC43 hgZGZDE4bjatfrl4xoPPQzyncGSLBJ6a9oISP/ITsfMJRmIlI9rd4kpBSc6ifIblOeMP n4l4uzeC64lDsmFnvZ/oLTm7/9w24ntls+wuFkzu8Ryi2l1eHyny+z43dO6UZa2dLTLW geWv+y7fXFd0X9jQSLV+ElBcgnLIXLzE5Hbe+TSsWlPkAJ+Zwg76EHvNd3ObTItP5uXm SiOAaNdvmsFhZPQndk8DOFScvEez/VzXQBwQpwpvT5rgBb0/VFUYoqjfei47QaM0YJwB lQbg== X-Gm-Message-State: AOPr4FURBqamiQgtWYLgBMa7I+fUdq0DCeTMkQuiRfZUDRz3dc1MyAhbegKfAqbrOOsWcwQG77qU4OSeDjnesA== MIME-Version: 1.0 X-Received: by 10.31.172.81 with SMTP id v78mr1240120vke.70.1461676111147; Tue, 26 Apr 2016 06:08:31 -0700 (PDT) Received: by 10.31.214.131 with HTTP; Tue, 26 Apr 2016 06:08:31 -0700 (PDT) In-Reply-To: <20160426115108.GC3033@acm.fritz.box> References: <20160424090035.87856.qmail@mail.muc.de> <20160424142313.GB3517@acm.fritz.box> <20160426115108.GC3033@acm.fritz.box> Date: Tue, 26 Apr 2016 15:08:31 +0200 Message-ID: Subject: Re: bug#23347: 25.0.92; Follow mode scrolling broken -- scrolls only one page From: Anders Lindgren To: Alan Mackenzie Content-Type: multipart/alternative; boundary=001a114408d461ba3d053162fd4c X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 23347 Cc: 23347@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) --001a114408d461ba3d053162fd4c Content-Type: text/plain; charset=UTF-8 Hi! I just tested this and I can confirm that it works, as far as I can tell! I tested the "old" scroll functions `follow-scroll-up' and `-down' and now they scroll the entire display, hence the bug I initially reported is fixed. I tested with positive and negative numerical arguments and the corresponding number of lines were scrolled, in the correct direction. I tested the new "window" scroll functions and they work as well -- with and without arguments. I noticed some area where this could be improved upon, however they are minor and I think we should address them after the emacs-25 release: + The new "window" scroll functions scroll almost a window. The effect is that normally the point is moved from one window to the next. However, if the cursor is at the bottom of a window the user do a `follow-scroll-up-window', the point ens up at the top of the same window, which could be a bit confusing. (In other words, skip the `next-screen-context-lines' part. When using Follow mode, there is enough context anyway.) + Now both `follow-scroll-up' and `follow-scroll-up-window' scroll ARG lines when presented with an argument. It would be nice if either one of them could scroll ARG windows instead. (Where "one window" could be seen as the number of lines of the current window.) I think it would make most sense to apply this change to `follow-scroll-up'. + Documentation: In `follow-scroll-up-window' -- we should mention the difference is compared to `scroll-up' (that the point isn't moved, if it can be displayed in another window). In `follow-scroll-up' -- Make it clear what the difference between this and `follow-scroll-up-window' is (that it scroll the entire display). Finally -- Many, many thanks for all the work you have put into this! -- Anders On Tue, Apr 26, 2016 at 1:51 PM, Alan Mackenzie wrote: > Hello, Anders. > > On Sun, Apr 24, 2016 at 05:37:57PM +0200, Anders Lindgren wrote: > > Hi! > > > Agreed. All three scroll commands (non-follow-mode scroll, scroll one > page, > > and scroll N pages) are useful. > > [ .... ] > > > Yes, I agree, `page' isn't a good choice. > > > What about `follow-scroll-up-keep-point'? That way it would be clear what > > the difference is between it and the normal scroll command. > > > If I would have designed Follow mode today, I probably would have used > your > > name, `follow-scroll-up-window', and named the N-page scroll > > `follow-scroll-up-window-group'. > > I've just used `follow-scroll-up-window' and > `follow-scroll-down-window'. At least, for now. > > [ .... ] > > > Anyway, here is what I think we can agree on: > > > 1. `follow-scroll-up/down' should scroll by N windows. > > > 2. There need to be commands in follow.el that scroll by 1 window as is > > > done by the current `follow-scroll-up/down'. You have suggested the > > > name `follow-scroll-up/down-one-page'. I have countered with > > > `follow-scroll-up/down-window'. > > > > If we can agree, I'm willing to amend follow.el. I think it's probably > > > too late for this fix to make it into Emacs 25.1, though. > > > > > > Well, give it a try. Feel free to pick a suitable name. If we come up > with > > a clean solution quickly John might accept it. > > OK. I had one or two minor problems with follow-scroll-up/down with a > non-nil ARG. In the end, I just extracted functionality from > follow-scroll-up/down-window into separate functions, and called those > from all four scrolling functions. > > Anyway, here is the patch I've come up with. Could you review it and > test it, please. Thanks! > > > diff --git a/lisp/follow.el b/lisp/follow.el > index 5801f79..3e23247 100644 > --- a/lisp/follow.el > +++ b/lisp/follow.el > @@ -532,6 +532,80 @@ follow-get-scrolled-point > ;; position... (This would also be corrected if we would have had a > ;; good redisplay abstraction.) > > +(defun follow-scroll-up-arg (arg) > + "Scroll the text in a follow mode window chain up by ARG lines. > +If ARG is nil, scroll the size of the current window. > + > +This is an internal function for `follow-scroll-up' and > +`follow-scroll-up-window'." > + (let ((opoint (point)) (owin (selected-window))) > + (while > + ;; If we are too near EOB, try scrolling the previous window. > + (condition-case nil (progn (scroll-up arg) nil) > + (end-of-buffer > + (condition-case nil (progn (follow-previous-window) t) > + (error > + (select-window owin) > + (goto-char opoint) > + (signal 'end-of-buffer nil)))))) > + (unless (and scroll-preserve-screen-position > + (get this-command 'scroll-command)) > + (goto-char opoint)) > + (setq follow-fixed-window t))) > + > +(defun follow-scroll-down-arg (arg) > + "Scroll the text in a follow mode window chain down by ARG lines. > +If ARG is nil, scroll the size of the current window. > + > +This is an internal function for `follow-scroll-down' and > +`follow-scroll-down-window'." > + (let ((opoint (point))) > + (scroll-down arg) > + (unless (and scroll-preserve-screen-position > + (get this-command 'scroll-command)) > + (goto-char opoint)) > + (setq follow-fixed-window t))) > + > +;;;###autoload > +(defun follow-scroll-up-window (&optional arg) > + "Scroll text in a Follow mode window up by that window's size. > +The other windows in the window chain will scroll synchronously. > + > +If called with no ARG, the `next-screen-context-lines' last lines of > +the window will be visible after the scroll. > + > +If called with an argument, scroll ARG lines up. > +Negative ARG means scroll downward. > + > +Works like `scroll-up' when not in Follow mode." > + (interactive "P") > + (cond ((not follow-mode) > + (scroll-up arg)) > + ((eq arg '-) > + (follow-scroll-down-window)) > + (t (follow-scroll-up-arg arg)))) > +(put 'follow-scroll-up-window 'scroll-command t) > + > +;;;###autoload > +(defun follow-scroll-down-window (&optional arg) > + "Scroll text in a Follow mode window down by that window's size. > +The other windows in the window chain will scroll synchronously. > + > +If called with no ARG, the `next-screen-context-lines' top lines of > +the window in the chain will be visible after the scroll. > + > +If called with an argument, scroll ARG lines down. > +Negative ARG means scroll upward. > + > +Works like `scroll-down' when not in Follow mode." > + (interactive "P") > + (cond ((not follow-mode) > + (scroll-down arg)) > + ((eq arg '-) > + (follow-scroll-up-window)) > + (t (follow-scroll-down-arg arg)))) > +(put 'follow-scroll-down-window 'scroll-command t) > + > ;;;###autoload > (defun follow-scroll-up (&optional arg) > "Scroll text in a Follow mode window chain up. > @@ -546,23 +620,18 @@ follow-scroll-up > (interactive "P") > (cond ((not follow-mode) > (scroll-up arg)) > - ((eq arg '-) > - (follow-scroll-down)) > - (t > - (let ((opoint (point)) (owin (selected-window))) > - (while > - ;; If we are too near EOB, try scrolling the previous > window. > - (condition-case nil (progn (scroll-up arg) nil) > - (end-of-buffer > - (condition-case nil (progn (follow-previous-window) t) > - (error > - (select-window owin) > - (goto-char opoint) > - (signal 'end-of-buffer nil)))))) > - (unless (and scroll-preserve-screen-position > - (get this-command 'scroll-command)) > - (goto-char opoint)) > - (setq follow-fixed-window t))))) > + (arg (follow-scroll-up-arg arg)) > + (t > + (let* ((windows (follow-all-followers)) > + (end (window-end (car (reverse windows))))) > + (if (eq end (point-max)) > + (signal 'end-of-buffer nil) > + (select-window (car windows)) > + ;; `window-end' might return nil. > + (if end > + (goto-char end)) > + (vertical-motion (- next-screen-context-lines)) > + (set-window-start (car windows) (point))))))) > (put 'follow-scroll-up 'scroll-command t) > > ;;;###autoload > @@ -579,15 +648,22 @@ follow-scroll-down > (interactive "P") > (cond ((not follow-mode) > (scroll-down arg)) > - ((eq arg '-) > - (follow-scroll-up)) > - (t > - (let ((opoint (point))) > - (scroll-down arg) > - (unless (and scroll-preserve-screen-position > - (get this-command 'scroll-command)) > - (goto-char opoint)) > - (setq follow-fixed-window t))))) > + (arg (follow-scroll-down-arg arg)) > + (t > + (let* ((windows (follow-all-followers)) > + (win (car (reverse windows))) > + (start (window-start (car windows)))) > + (if (eq start (point-min)) > + (signal 'beginning-of-buffer nil) > + (select-window win) > + (goto-char start) > + (vertical-motion (- (- (window-height win) > + (if header-line-format 2 1) > + next-screen-context-lines))) > + (set-window-start win (point)) > + (goto-char start) > + (vertical-motion (- next-screen-context-lines 1)) > + (setq follow-internal-force-redisplay t)))))) > (put 'follow-scroll-down 'scroll-command t) > > (declare-function comint-adjust-point "comint" (window)) > > > > -- Anders > > -- > Alan Mackenzie (Nuremberg, Germany). > --001a114408d461ba3d053162fd4c Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi!

I just tested this and I can confir= m that it works, as far as I can tell!


<= div>I tested the "old" scroll functions `follow-scroll-up' an= d `-down' and now they scroll the entire display, hence the bug I initi= ally reported is fixed.

I tested with positive and= negative numerical arguments and the corresponding number of lines were sc= rolled, in the correct direction.

I tested the new= "window" scroll functions and they work as well -- with and with= out arguments.


I noticed some area = where this could be improved upon, however they are minor and I think we sh= ould address them after the emacs-25 release:

+ Th= e new "window" scroll functions scroll almost a window. The effec= t is that normally the point is moved from one window to the next. However,= if the cursor is at the bottom of a window the user do a `follow-scroll-up= -window', the point ens up at the top of the same window, which could b= e a bit confusing. (In other words, skip the `next-screen-context-lines'= ; part. When using Follow mode, there is enough context anyway.)
=
+ Now both `follow-scroll-up' and `follow-scroll-up-wind= ow' scroll ARG lines when presented with an argument. It would be nice = if either one of them could scroll ARG windows instead. (Where "one wi= ndow" could be seen as the number of lines of the current window.) I t= hink it would make most sense to apply this change to `follow-scroll-up'= ;.

+ Documentation:

In `f= ollow-scroll-up-window' -- we should mention the difference is compared= to `scroll-up' (that the point isn't moved, if it can be displayed= in another window).

In `follow-scroll-up'= -- Make it clear what the difference between this and `follow-scroll-up-wi= ndow' is (that it scroll the entire display).

=
Finally -- Many, many thanks for all the work you have put i= nto this!

=C2=A0 =C2=A0 -- Anders


On Tue, = Apr 26, 2016 at 1:51 PM, Alan Mackenzie <acm@muc.de> wrote:
Hello, Anders.

On Sun, Apr 24, 2016 at 05:37:57PM +0200, Anders Lindgren wrote:
> Hi!

> Agreed. All three scroll commands (non-follow-mode scroll= , scroll one page,
> and scroll N pages) are useful.

[ .... ]

> Yes, I agree, `page' isn't a good choice.

> What about `follow-scroll-up-keep-point'? That way it would be cle= ar what
> the difference is between it and the normal scroll command.

> If I would have designed Follow mode today, I probably would have used= your
> name, `follow-scroll-up-window', and named the N-page scroll
> `follow-scroll-up-window-group'.

I've just used `follow-scroll-up-window' and
`follow-scroll-down-window'.=C2=A0 At least, for now.

[ .... ]

> Anyway, here is what I think we can agree on:
> > 1. `follow-scroll-up/down' should scroll by N windows.
> > 2. There need to be commands in follow.el that scroll by 1 window= as is
> >=C2=A0 =C2=A0done by the current `follow-scroll-up/down'.=C2= =A0 You have suggested the
> >=C2=A0 =C2=A0name `follow-scroll-up/down-one-page'.=C2=A0 I ha= ve countered with
> >=C2=A0 =C2=A0`follow-scroll-up/down-window'.

> > If we can agree, I'm willing to amend follow.el.=C2=A0 I thin= k it's probably
> > too late for this fix to make it into Emacs 25.1, though.
> >

> Well, give it a try. Feel free to pick a suitable name. If we come up = with
> a clean solution quickly John might accept it.

OK.=C2=A0 I had one or two minor problems with follow-scroll-up/down= with a
non-nil ARG.=C2=A0 In the end, I just extracted functionality from
follow-scroll-up/down-window into separate functions, and called those
from all four scrolling functions.

Anyway, here is the patch I've come up with.=C2=A0 Could you review it = and
test it, please.=C2=A0 Thanks!


diff --git a/lisp/follow.el b/lisp/follow.el
index 5801f79..3e23247 100644
--- a/lisp/follow.el
+++ b/lisp/follow.el
@@ -532,6 +532,80 @@ follow-get-scrolled-point
=C2=A0;; position...=C2=A0 (This would also be corrected if we would have h= ad a
=C2=A0;; good redisplay abstraction.)

+(defun follow-scroll-up-arg (arg)
+=C2=A0 "Scroll the text in a follow mode window chain up by ARG lines= .
+If ARG is nil, scroll the size of the current window.
+
+This is an internal function for `follow-scroll-up' and
+`follow-scroll-up-window'."
+=C2=A0 (let ((opoint (point))=C2=A0 (owin (selected-window)))
+=C2=A0 =C2=A0 (while
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 ;; If we are too near EOB, try scrolling the p= revious window.
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 (condition-case nil (progn (scroll-up arg) nil= )
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (end-of-buffer
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(condition-case nil (progn (follo= w-previous-window) t)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(error
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (select-window owin)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (goto-char opoint)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (signal 'end-of-buffe= r nil))))))
+=C2=A0 =C2=A0 (unless (and scroll-preserve-screen-position
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(get this-co= mmand 'scroll-command))
+=C2=A0 =C2=A0 =C2=A0 (goto-char opoint))
+=C2=A0 =C2=A0 (setq follow-fixed-window t)))
+
+(defun follow-scroll-down-arg (arg)
+=C2=A0 "Scroll the text in a follow mode window chain down by ARG lin= es.
+If ARG is nil, scroll the size of the current window.
+
+This is an internal function for `follow-scroll-down' and
+`follow-scroll-down-window'."
+=C2=A0 (let ((opoint (point)))
+=C2=A0 =C2=A0 (scroll-down arg)
+=C2=A0 =C2=A0 (unless (and scroll-preserve-screen-position
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(get this-co= mmand 'scroll-command))
+=C2=A0 =C2=A0 =C2=A0 (goto-char opoint))
+=C2=A0 =C2=A0 (setq follow-fixed-window t)))
+
+;;;###autoload
+(defun follow-scroll-up-window (&optional arg)
+=C2=A0 "Scroll text in a Follow mode window up by that window's s= ize.
+The other windows in the window chain will scroll synchronously.
+
+If called with no ARG, the `next-screen-context-lines' last lines of +the window will be visible after the scroll.
+
+If called with an argument, scroll ARG lines up.
+Negative ARG means scroll downward.
+
+Works like `scroll-up' when not in Follow mode."
+=C2=A0 (interactive "P")
+=C2=A0 (cond ((not follow-mode)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 (scroll-up arg))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0((eq arg '-)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 (follow-scroll-down-window))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0(t (follow-scroll-up-arg arg))))
+(put 'follow-scroll-up-window 'scroll-command t)
+
+;;;###autoload
+(defun follow-scroll-down-window (&optional arg)
+=C2=A0 "Scroll text in a Follow mode window down by that window's= size.
+The other windows in the window chain will scroll synchronously.
+
+If called with no ARG, the `next-screen-context-lines' top lines of +the window in the chain will be visible after the scroll.
+
+If called with an argument, scroll ARG lines down.
+Negative ARG means scroll upward.
+
+Works like `scroll-down' when not in Follow mode."
+=C2=A0 (interactive "P")
+=C2=A0 (cond ((not follow-mode)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 (scroll-down arg))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0((eq arg '-)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 (follow-scroll-up-window))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0(t (follow-scroll-down-arg arg))))
+(put 'follow-scroll-down-window 'scroll-command t)
+
=C2=A0;;;###autoload
=C2=A0(defun follow-scroll-up (&optional arg)
=C2=A0 =C2=A0"Scroll text in a Follow mode window chain up.
@@ -546,23 +620,18 @@ follow-scroll-up
=C2=A0 =C2=A0(interactive "P")
=C2=A0 =C2=A0(cond ((not follow-mode)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(scroll-up arg))
-=C2=A0 =C2=A0 =C2=A0 =C2=A0((eq arg '-)
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 (follow-scroll-down))
-=C2=A0 =C2=A0 =C2=A0 =C2=A0(t
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 (let ((opoint (point))=C2=A0 (owin (selected-w= indow)))
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (while
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 ;; If we are too near EOB= , try scrolling the previous window.
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (condition-case nil (prog= n (scroll-up arg) nil)
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (end-of-buffer
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(condition-c= ase nil (progn (follow-previous-window) t)
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(erro= r
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (sel= ect-window owin)
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (got= o-char opoint)
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (sig= nal 'end-of-buffer nil))))))
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (unless (and scroll-preserve-screen-pos= ition
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0(get this-command 'scroll-command))
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (goto-char opoint))
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (setq follow-fixed-window t)))))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0(arg (follow-scroll-up-arg arg))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 (t
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 (let* ((windows (follow-all-followers))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(end (window-end (c= ar (reverse windows)))))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (if (eq end (point-max))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (signal 'end-of-buffe= r nil)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (select-window (car windows)) +=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 ;; `window-end' might return= nil.
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (if end
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (goto-char end)) +=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (vertical-motion (- next-screen-= context-lines))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (set-window-start (car windows) = (point)))))))
=C2=A0(put 'follow-scroll-up 'scroll-command t)

=C2=A0;;;###autoload
@@ -579,15 +648,22 @@ follow-scroll-down
=C2=A0 =C2=A0(interactive "P")
=C2=A0 =C2=A0(cond ((not follow-mode)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(scroll-down arg))
-=C2=A0 =C2=A0 =C2=A0 =C2=A0((eq arg '-)
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 (follow-scroll-up))
-=C2=A0 =C2=A0 =C2=A0 =C2=A0(t
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 (let ((opoint (point)))
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (scroll-down arg)
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (unless (and scroll-preserve-screen-pos= ition
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0(get this-command 'scroll-command))
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (goto-char opoint))
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (setq follow-fixed-window t)))))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0(arg (follow-scroll-down-arg arg))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 (t
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 (let* ((windows (follow-all-followers))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(win (car (reverse = windows)))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(start (window-star= t (car windows))))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (if (eq start (point-min))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (signal 'beginning-of= -buffer nil)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (select-window win)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (goto-char start)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (vertical-motion (- (- (window-h= eight win)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(if header-line-format = 2 1)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0next-screen-context-lin= es)))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (set-window-start win (point)) +=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (goto-char start)
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (vertical-motion (- next-screen-= context-lines 1))
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (setq follow-internal-force-redi= splay t))))))
=C2=A0(put 'follow-scroll-down 'scroll-command t)

=C2=A0(declare-function comint-adjust-point "comint" (window))


>=C2=A0 =C2=A0 =C2=A0-- Anders

--
Alan Mackenzie (Nuremberg, Germany).

--001a114408d461ba3d053162fd4c-- From debbugs-submit-bounces@debbugs.gnu.org Fri Apr 29 11:02:50 2016 Received: (at 23347-done) by debbugs.gnu.org; 29 Apr 2016 15:02:50 +0000 Received: from localhost ([127.0.0.1]:55471 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1aw9wQ-0006BL-9e for submit@debbugs.gnu.org; Fri, 29 Apr 2016 11:02:50 -0400 Received: from mail.muc.de ([193.149.48.3]:42751) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1aw9wO-0006BD-Fj for 23347-done@debbugs.gnu.org; Fri, 29 Apr 2016 11:02:48 -0400 Received: (qmail 60499 invoked by uid 3782); 29 Apr 2016 15:02:47 -0000 Received: from acm.muc.de (p579E8C72.dip0.t-ipconnect.de [87.158.140.114]) by colin.muc.de (tmda-ofmipd) with ESMTP; Fri, 29 Apr 2016 17:02:46 +0200 Received: (qmail 13240 invoked by uid 1000); 29 Apr 2016 15:02:46 -0000 Date: Fri, 29 Apr 2016 15:02:46 +0000 To: 23347-done@debbugs.gnu.org Subject: Re: bug#23347: 25.0.92; Follow mode scrolling broken -- scrolls only one page Message-ID: <20160429150246.GC12345@acm.fritz.box> References: <20160424090035.87856.qmail@mail.muc.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) X-Delivery-Agent: TMDA/1.1.12 (Macallan) From: Alan Mackenzie X-Primary-Address: acm@muc.de X-Spam-Score: -1.0 (-) X-Debbugs-Envelope-To: 23347-done Cc: Anders Lindgren X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Bug fixed in emacs-25 branch. -- Alan Mackenzie (Nuremberg, Germany). From unknown Thu Sep 11 06:21:13 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sat, 28 May 2016 11:24:07 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator