GNU bug report logs - #31325
27.0.50; PROPOSAL: introduce a new function to recenter without redisplaying the frame

Previous Next

Package: emacs;

Reported by: John Shahid <jvshahid <at> gmail.com>

Date: Tue, 1 May 2018 00:49:02 UTC

Severity: wishlist

Found in version 27.0.50

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Eli Zaretskii <eliz <at> gnu.org>
To: John Shahid <jvshahid <at> gmail.com>
Cc: 31325 <at> debbugs.gnu.org, monnier <at> iro.umontreal.ca, drew.adams <at> oracle.com
Subject: bug#31325: 27.0.50; PROPOSAL: introduce a new function to recenter without redisplaying the frame
Date: Mon, 02 Jul 2018 18:18:20 +0300
> From: John Shahid <jvshahid <at> gmail.com>
> Cc: Eli Zaretskii <eliz <at> gnu.org>, 31325 <at> debbugs.gnu.org, monnier <at> iro.umontreal.ca
> Date: Mon, 02 Jul 2018 02:27:22 +0000
> 
> Are you confusing redisplaying the window that is displaying the buffer
> with clearing and redisplaying the entire tty frame ? This patch
> addresses the latter.  To be clear, `recenter' will redisplay the window
> displaying the buffer and this patch doesn't change that behavior.

Indeed, I think there's some confusion here.  Recentering a window
will always trigger redisplay of that window if the new point is out
of view, or if enters the display margins.  But it doesn't necessarily
clear and redraw the entire frame.

For the record: historically, 'recenter' always cleared the entire
frame and drew it anew.  Then, almost exactly 9 years ago, we changed
the default behavior to clear and redraw frame only on TTYs, and
introduced a variable, recenter-redisplay, to disable redrawing even
of TTY frames.

The current change goes a step further in the same direction: it
modifies the behavior of non-interactive calls of 'recenter', such
that even on a TTY it doesn't by default redraw the entire frame,
unless the caller explicitly requests that.  If not specifically
requested, 'recenter' called non-interactively will just recenter (and
trigger redisplay of the window which it recentered, if necessary).
The rationale for this change is that the vast majority of
non-interactive callers of 'recenter' have no reason to redraw the
entire frame, and recenter-redisplay is a knob meant to control only
the interactive behavior.




This bug report was last modified 6 years and 322 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.