GNU bug report logs - #12170
save-excursion fails boundary case with recenter

Previous Next

Package: emacs;

Reported by: "Bill Brodie" <wbrodie <at> panix.com>

Date: Fri, 10 Aug 2012 02:01:02 UTC

Severity: normal

Tags: notabug

Done: npostavs <at> users.sourceforge.net

Bug is archived. No further changes may be made.

Full log


Message #50 received at 12170 <at> debbugs.gnu.org (full text, mbox):

From: martin rudalics <rudalics <at> gmx.at>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 12170 <at> debbugs.gnu.org, Bill Brodie <wbrodie <at> panix.com>
Subject: Re: bug#12170: save-excursion fails boundary case with recenter
Date: Sat, 11 Aug 2012 11:31:32 +0200
>> (1) By "window height", I meant the number of lines displayed for the actual
>> buffer, not counting the mode line or minibuffer.  It turns out this is one
>> less than the value returned by `window-height'.
>
> As documented, window-height returns the height of the window
> including the mode line (and the header line, if there is any).  So
> the above is expected.

To avoid this confusion `window-total-height' should be used instead of
`window-height'.  The "number of lines displayed for the actual buffer"
is returned by the function `window-body-height'.

martin




This bug report was last modified 8 years and 62 days ago.

Previous Next


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