GNU bug report logs -
#28879
26.0.90; Narrowed line numbers shown with display-line-numbers-widen
Previous Next
Reported by: Andy Moreton <andrewjmoreton <at> gmail.com>
Date: Tue, 17 Oct 2017 20:41:01 UTC
Severity: normal
Found in version 26.0.90
Done: Eli Zaretskii <eliz <at> gnu.org>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 28879 in the body.
You can then email your comments to 28879 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#28879
; Package
emacs
.
(Tue, 17 Oct 2017 20:41:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Andy Moreton <andrewjmoreton <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Tue, 17 Oct 2017 20:41:01 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
From emacs -Q:
1) Open a lisp file
(setq display-line-numbers-widen t)
M-x display-line-numbers-mode
2) Move point inside a function
M-x narrow-to-defun
3) M-x widen
After (2) the window shows line numbers relative to the start of
the buffer, as expected.
After (3), the window shows line numbers starting from 1 for the
narrowed region. After the next mouse or keyboard input, the line
numbers are displayed normally.
Thus it seems that when display-line-numbers-widen is non-nil the line
numbers are not recomputed after widen until then next input.
In GNU Emacs 26.0.90 (build 9, x86_64-w64-mingw32)
of 2017-10-17 built on QUIETUS
Repository revision: 2e1b3522b8562f94a98fed07aeddb6b5ba0dbc6c
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#28879
; Package
emacs
.
(Wed, 18 Oct 2017 16:23:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 28879 <at> debbugs.gnu.org (full text, mbox):
> From: Andy Moreton <andrewjmoreton <at> gmail.com>
> Date: Tue, 17 Oct 2017 21:40:16 +0100
>
> From emacs -Q:
> 1) Open a lisp file
> (setq display-line-numbers-widen t)
> M-x display-line-numbers-mode
> 2) Move point inside a function
> M-x narrow-to-defun
> 3) M-x widen
>
> After (2) the window shows line numbers relative to the start of
> the buffer, as expected.
>
> After (3), the window shows line numbers starting from 1 for the
> narrowed region. After the next mouse or keyboard input, the line
> numbers are displayed normally.
Right. And if your Emacs is built with --enable-checking (which is
something I advise for the first couple of pretest of a new release),
you might be able to trigger an assertion violation by repeating the
above recipe several times.
> Thus it seems that when display-line-numbers-widen is non-nil the line
> numbers are not recomputed after widen until then next input.
Actually, the numbers have been recomputed, as you see them change on
display. They just were recomputed incorrectly: the logic related to
widening failed to catch the first redisplay cycle after 'widen',
which is special. (In general, line numbers are computed as part of
displaying a window, so whenever you see redisplay, you know the line
numbers were recomputed, at least for some lines.)
Should be fixed now. Thanks for reporting this.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#28879
; Package
emacs
.
(Wed, 18 Oct 2017 17:41:01 GMT)
Full text and
rfc822 format available.
Message #11 received at submit <at> debbugs.gnu.org (full text, mbox):
On Wed 18 Oct 2017, Eli Zaretskii wrote:
>> From: Andy Moreton <andrewjmoreton <at> gmail.com>
>> Date: Tue, 17 Oct 2017 21:40:16 +0100
>>
>> From emacs -Q:
>> 1) Open a lisp file
>> (setq display-line-numbers-widen t)
>> M-x display-line-numbers-mode
>> 2) Move point inside a function
>> M-x narrow-to-defun
>> 3) M-x widen
>>
>> After (2) the window shows line numbers relative to the start of
>> the buffer, as expected.
>>
>> After (3), the window shows line numbers starting from 1 for the
>> narrowed region. After the next mouse or keyboard input, the line
>> numbers are displayed normally.
>
> Right. And if your Emacs is built with --enable-checking (which is
> something I advise for the first couple of pretest of a new release),
> you might be able to trigger an assertion violation by repeating the
> above recipe several times.
Good point - mine was built without it.
> Should be fixed now. Thanks for reporting this.
Confirmed fixed.
Reply sent
to
Eli Zaretskii <eliz <at> gnu.org>
:
You have taken responsibility.
(Wed, 18 Oct 2017 17:59:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Andy Moreton <andrewjmoreton <at> gmail.com>
:
bug acknowledged by developer.
(Wed, 18 Oct 2017 17:59:03 GMT)
Full text and
rfc822 format available.
Message #16 received at 28879-done <at> debbugs.gnu.org (full text, mbox):
> From: Andy Moreton <andrewjmoreton <at> gmail.com>
> Date: Wed, 18 Oct 2017 18:39:12 +0100
>
> > Should be fixed now. Thanks for reporting this.
>
> Confirmed fixed.
Thanks, closing.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Thu, 16 Nov 2017 12:24:08 GMT)
Full text and
rfc822 format available.
This bug report was last modified 7 years and 268 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.