GNU bug report logs - #66283
30.0.50; which-function-mode: When configured to display in header, and toggling off, then does not remove header

Previous Next

Package: emacs;

Reported by: Mekeor Melire <mekeor <at> posteo.de>

Date: Sat, 30 Sep 2023 21:09:01 UTC

Severity: minor

Tags: confirmed, patch

Found in version 30.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: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#66283: closed (30.0.50; which-function-mode: When configured
 to display in header, and toggling off, then does not remove header)
Date: Sun, 29 Oct 2023 11:26:02 +0000
[Message part 1 (text/plain, inline)]
Your message dated Sun, 29 Oct 2023 13:24:04 +0200
with message-id <83r0ldbrjf.fsf <at> gnu.org>
and subject line Re: bug#66283: 30.0.50; which-function-mode: When configured to display in header, and toggling off, then does not remove header
has caused the debbugs.gnu.org bug report #66283,
regarding 30.0.50; which-function-mode: When configured to display in header, and toggling off, then does not remove header
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
66283: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=66283
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Mekeor Melire <mekeor <at> posteo.de>
To: bug-gnu-emacs <at> gnu.org
Cc: Author <sbaugh <at> catern.com>, Committer <eliz <at> gnu.org>
Subject: 30.0.50; which-function-mode: When configured to display in header,
 and toggling off, then does not remove header
Date: Sat, 30 Sep 2023 20:41:05 +0000
Execute: emacs -Q

Configure Which Function Mode to display in header by evaluating 
the following; note that this is a new feature in Emacs 30: 
(customize-set-variable 'which-func-display 'header)

Toggle Which Function Mode on by typing: M-x which-function-mode 
RET

Toggle Which Function Mode off by typing again: M-x 
which-function-mode RET

You can see a dysfunctional header. (It won't be update because 
Which Function Mode is off.) To be precise, the value of variable 
`header-line-format' is '(("" which-func-format " ")). Apparently, 
this variable has not been cleaned up appropriately. This is the 
job of the function `which-func--disable'. [1]

In order to test the `which-func--disable' function, type: M-: (which-func--disable) RET

The header disappeared. The value of variable `header-line-format' is `nil'. This means, that the function does its job well. Apparently, it's not being called when toggling off. [2]

[1]: https://git.sv.gnu.org/cgit/emacs.git/tree/lisp/progmodes/which-func.el?h=35fbf6f15830f576fd1909f4a8d30e7ba1d777bd#n225

[2]: Where is the "Turn it off." comment here? https://git.sv.gnu.org/cgit/emacs.git/tree/lisp/progmodes/which-func.el?h=35fbf6f15830f576fd1909f4a8d30e7ba1d777bd#n289

--
In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 
3.24.37, cairo version 1.16.0)
Windowing system distributor 'The X.Org Foundation', version 
11.0.12101004
System Description: Guix System


[Message part 3 (message/rfc822, inline)]
From: Eli Zaretskii <eliz <at> gnu.org>
To: sbaugh <at> catern.com
Cc: mekeor <at> posteo.de, sbaugh <at> janestreet.com, 66283-done <at> debbugs.gnu.org,
 stefankangas <at> gmail.com
Subject: Re: bug#66283: 30.0.50; which-function-mode: When configured to
 display in header, and toggling off, then does not remove header
Date: Sun, 29 Oct 2023 13:24:04 +0200
> From: sbaugh <at> catern.com
> Date: Sat, 21 Oct 2023 14:43:30 +0000 (UTC)
> Cc: Spencer Baugh <sbaugh <at> janestreet.com>, mekeor <at> posteo.de,
> 	66283 <at> debbugs.gnu.org, stefankangas <at> gmail.com
> 
> > Thanks, but how about some tests for these fixes?  It's high time
> > which-mode had some test suite, I think.
> 
> Sure, here's a patch including a test.

Thanks, installed on the master branch, and closing the bug.


This bug report was last modified 1 year and 207 days ago.

Previous Next


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