GNU bug report logs - #20841
25.0.50; Turning off `which-function-mode' does not remove its last effect from the minibuffer

Previous Next

Package: emacs;

Reported by: Drew Adams <drew.adams <at> oracle.com>

Date: Thu, 18 Jun 2015 01:26:01 UTC

Severity: minor

Tags: moreinfo, unreproducible

Found in version 25.0.50

Done: Lars Ingebrigtsen <larsi <at> gnus.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 20841 in the body.
You can then email your comments to 20841 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#20841; Package emacs. (Thu, 18 Jun 2015 01:26:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Drew Adams <drew.adams <at> oracle.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Thu, 18 Jun 2015 01:26:02 GMT) Full text and rfc822 format available.

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

From: Drew Adams <drew.adams <at> oracle.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 25.0.50; Turning off `which-function-mode' does not remove its last
 effect from the minibuffer
Date: Wed, 17 Jun 2015 18:25:16 -0700 (PDT)
Subject line says it all.


In GNU Emacs 25.0.50.1 (i686-pc-mingw32)
 of 2014-10-20 on LEG570
Bzr revision: 118168 rgm <at> gnu.org-20141020195941-icp42t8ttcnud09g
Windowing system distributor `Microsoft Corp.', version 6.1.7601
Configured using:
 `configure --enable-checking=yes,glyphs CPPFLAGS=-DGLYPH_DEBUG=1'




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#20841; Package emacs. (Sat, 30 Apr 2016 20:02:02 GMT) Full text and rfc822 format available.

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

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Drew Adams <drew.adams <at> oracle.com>
Cc: 20841 <at> debbugs.gnu.org
Subject: Re: bug#20841: 25.0.50;
 Turning off `which-function-mode' does not remove its last effect
 from the minibuffer
Date: Sat, 30 Apr 2016 22:01:15 +0200
Drew Adams <drew.adams <at> oracle.com> writes:

> Subject line says it all.

I'm unable to reproduce this on the trunk.  I see that there have been
changes to the mode in the last year, but skimming the changes, I don't
see anything in the "switch the mode off" path...

Are you still seeing this?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#20841; Package emacs. (Sat, 30 Apr 2016 20:42:02 GMT) Full text and rfc822 format available.

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

From: Drew Adams <drew.adams <at> oracle.com>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: 20841 <at> debbugs.gnu.org
Subject: RE: bug#20841: 25.0.50; Turning off `which-function-mode' does not
 remove its last effect from the minibuffer
Date: Sat, 30 Apr 2016 12:41:24 -0800 (GMT-08:00)
> > Subject line says it all.
> 
> I'm unable to reproduce this on the trunk.  I see that there have been
> changes to the mode in the last year, but skimming the changes, I don't
> see anything in the "switch the mode off" path...
> 
> Are you still seeing this?

Yes, I'm still seeing it.  I turn it off and I still see things
like `[Documentation]' and `[???]' in the mode line of existing
buffers.

When this is true of *Help*, for instance, i.e., it remains
in the mode line after I've toggled it off, if I then ask
for something else to be displayed in *Help* (e.g. do `C-h f'),
then it is removed from the mode line.

I see this in my setup, but my setup does nothing with
`which-function-mode'.  One guess is that the bug might
manifest itself only if you have a standalone minibuffer.

Another guess might be (since ediff uses a separate control
frame (?)) that it is similar to whatever is behind this
comment in the code:

;; FIXME: Why does ediff require special support?

Another guess is that it might have to do with
`mode-line-misc-info'.

After I've turned the mode off I see that the value of
variable `which-func-mode' remains `t' in buffers, even
though the global value has been changed to `nil'.

I don't have time to try to debug this.
Close it if no one else has the time.  I no longer
turn the mode on at all, to avoid the annoyance.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#20841; Package emacs. (Sat, 07 May 2016 12:45:01 GMT) Full text and rfc822 format available.

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

From: Michael Heerdegen <michael_heerdegen <at> web.de>
To: Drew Adams <drew.adams <at> oracle.com>
Cc: 20841 <at> debbugs.gnu.org, Lars Ingebrigtsen <larsi <at> gnus.org>
Subject: Re: bug#20841: 25.0.50;
 Turning off `which-function-mode' does not remove its last effect
 from the minibuffer
Date: Sat, 07 May 2016 14:44:06 +0200
Drew Adams <drew.adams <at> oracle.com> writes:

> Another guess is that it might have to do with
> `mode-line-misc-info'.
>
> After I've turned the mode off I see that the value of
> variable `which-func-mode' remains `t' in buffers, even
> though the global value has been changed to `nil'.

Bingo - I came to the same conclusion.  The mode-line uses the variable
which-func-mode that is not changed when toggling `which-function-mode'.

I guess this just has been forgotten to be updated after the mode had
been renamed.


Michael.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#20841; Package emacs. (Sat, 07 May 2016 12:56:02 GMT) Full text and rfc822 format available.

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

From: Michael Heerdegen <michael_heerdegen <at> web.de>
To: Drew Adams <drew.adams <at> oracle.com>
Cc: 20841 <at> debbugs.gnu.org, Lars Ingebrigtsen <larsi <at> gnus.org>
Subject: Re: bug#20841: 25.0.50;
 Turning off `which-function-mode' does not remove its last effect
 from the minibuffer
Date: Sat, 07 May 2016 14:55:08 +0200
Michael Heerdegen <michael_heerdegen <at> web.de> writes:

> I guess this just has been forgotten to be updated after the mode had
> been renamed.

Though, I think the intention had been to keep the name
`which-func-mode' for the mode variable.  So I guess we should just add
a :variable spec to the definition of `which-function-mode'.  But hmm,
no, `which-function-mode' is also used as a variable in the code, see
`which-func-ff-hook'.

Confusing.

So maybe just change the variable name of the mode-line element?


Michael.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#20841; Package emacs. (Mon, 31 Aug 2020 02:12:02 GMT) Full text and rfc822 format available.

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

From: Stefan Kangas <stefan <at> marxist.se>
To: Drew Adams <drew.adams <at> oracle.com>
Cc: 20841 <at> debbugs.gnu.org, Lars Ingebrigtsen <larsi <at> gnus.org>
Subject: Re: bug#20841: 25.0.50; Turning off `which-function-mode' does not
 remove its last effect from the minibuffer
Date: Mon, 31 Aug 2020 02:11:18 +0000
tags 20841 + moreinfo unreproducible
thanks

Drew Adams <drew.adams <at> oracle.com> writes:

>> > Subject line says it all.
>>
>> I'm unable to reproduce this on the trunk.  I see that there have been
>> changes to the mode in the last year, but skimming the changes, I don't
>> see anything in the "switch the mode off" path...
>>
>> Are you still seeing this?
>
> Yes, I'm still seeing it.  I turn it off and I still see things
> like `[Documentation]' and `[???]' in the mode line of existing
> buffers.
>
> When this is true of *Help*, for instance, i.e., it remains
> in the mode line after I've toggled it off, if I then ask
> for something else to be displayed in *Help* (e.g. do `C-h f'),
> then it is removed from the mode line.
>
> I see this in my setup, but my setup does nothing with
> `which-function-mode'.  One guess is that the bug might
> manifest itself only if you have a standalone minibuffer.

I can't reproduce this under "emacs -Q" either.

I think we need more information here.  I suspect that this issue is
related to some package or configuration you do, possibly with regards
to the mode-line.

> Another guess might be (since ediff uses a separate control
> frame (?)) that it is similar to whatever is behind this
> comment in the code:
>
> ;; FIXME: Why does ediff require special support?

Possibly.  You could try running this to see if it makes any difference:

    (which-func-update-1 (get-buffer-window))

> Another guess is that it might have to do with
> `mode-line-misc-info'.

After my attempts reproducing the bug and reading the code, I doubt
that.  But it's possible.

> After I've turned the mode off I see that the value of
> variable `which-func-mode' remains `t' in buffers, even
> though the global value has been changed to `nil'.

That variable is t in buffers that support which-function-mode.  IOW,
this is expected.

> I don't have time to try to debug this.
> Close it if no one else has the time.  I no longer
> turn the mode on at all, to avoid the annoyance.

Maybe you have more time to investigate this today than you did when
this was first reported?

Lacking more information, I unfortunately think it will be hard to get
much further here.




Added tag(s) unreproducible and moreinfo. Request was from Stefan Kangas <stefan <at> marxist.se> to control <at> debbugs.gnu.org. (Mon, 31 Aug 2020 02:12:03 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#20841; Package emacs. (Mon, 31 Aug 2020 02:27:01 GMT) Full text and rfc822 format available.

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

From: Drew Adams <drew.adams <at> oracle.com>
To: Stefan Kangas <stefan <at> marxist.se>
Cc: 20841 <at> debbugs.gnu.org, Lars Ingebrigtsen <larsi <at> gnus.org>
Subject: RE: bug#20841: 25.0.50; Turning off `which-function-mode' does not
 remove its last effect from the minibuffer
Date: Sun, 30 Aug 2020 19:26:32 -0700 (PDT)
> Maybe you have more time to investigate this today than you did when
> this was first reported?
> 
> Lacking more information, I unfortunately think it will be hard to get
> much further here.

I don't understand.  Did you read Michael Heerdegen's
mails in this thread?  He explains the problem, no?




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#20841; Package emacs. (Mon, 31 Aug 2020 02:54:02 GMT) Full text and rfc822 format available.

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

From: Stefan Kangas <stefan <at> marxist.se>
To: Drew Adams <drew.adams <at> oracle.com>
Cc: 20841 <at> debbugs.gnu.org, Lars Ingebrigtsen <larsi <at> gnus.org>
Subject: RE: bug#20841: 25.0.50; Turning off `which-function-mode' does not
 remove its last effect from the minibuffer
Date: Mon, 31 Aug 2020 02:53:16 +0000
Drew Adams <drew.adams <at> oracle.com> writes:

> I don't understand.  Did you read Michael Heerdegen's
> mails in this thread?  He explains the problem, no?

Yes, I read his replies and looked into what he suggested.  I can't see
how his posts explain the problem.

He was not clear over the difference between the confusingly named
variables which-function-mode and which-func-mode.  That confusion has
nothing to do with the mode line not updating AFAICT.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#20841; Package emacs. (Sat, 03 Oct 2020 22:22:02 GMT) Full text and rfc822 format available.

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

From: Michael Heerdegen <michael_heerdegen <at> web.de>
To: Stefan Kangas <stefan <at> marxist.se>
Cc: 20841 <at> debbugs.gnu.org, Lars Ingebrigtsen <larsi <at> gnus.org>,
 Drew Adams <drew.adams <at> oracle.com>
Subject: Re: bug#20841: 25.0.50; Turning off `which-function-mode' does not
 remove its last effect from the minibuffer
Date: Sun, 04 Oct 2020 00:20:57 +0200
Stefan Kangas <stefan <at> marxist.se> writes:

> > I don't understand.  Did you read Michael Heerdegen's
> > mails in this thread?  He explains the problem, no?
>
> Yes, I read his replies and looked into what he suggested.  I can't see
> how his posts explain the problem.
>
> He was not clear over the difference between the confusingly named
> variables which-function-mode and which-func-mode.  That confusion has
> nothing to do with the mode line not updating AFAICT.

No, I had understood the problem, but I guess it has been fixed in the
meantime - possibly

  cbfb1295554 Stefan Monnier  Improve disabling the mode

The problem had been that the mode var and the var used by the mode-line
to decide if there is anything to show were different and disabling the
mode didn't change the other var so the mode line display was not turned
off.  After the above commit the mode line display is only on when both
variables are non-nil so I think he fixed it without knowing of this
report.

Michael.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#20841; Package emacs. (Sun, 04 Oct 2020 14:01:02 GMT) Full text and rfc822 format available.

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

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Michael Heerdegen <michael_heerdegen <at> web.de>
Cc: 20841 <at> debbugs.gnu.org, Stefan Kangas <stefan <at> marxist.se>,
 Drew Adams <drew.adams <at> oracle.com>
Subject: Re: bug#20841: 25.0.50; Turning off `which-function-mode' does not
 remove its last effect from the minibuffer
Date: Sun, 04 Oct 2020 16:00:16 +0200
Michael Heerdegen <michael_heerdegen <at> web.de> writes:

> The problem had been that the mode var and the var used by the mode-line
> to decide if there is anything to show were different and disabling the
> mode didn't change the other var so the mode line display was not turned
> off.  After the above commit the mode line display is only on when both
> variables are non-nil so I think he fixed it without knowing of this
> report.

Ah, right.  Thanks for digging into this; closing the report.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




bug closed, send any further explanations to 20841 <at> debbugs.gnu.org and Drew Adams <drew.adams <at> oracle.com> Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Sun, 04 Oct 2020 14:01:02 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 02 Nov 2020 12:24:05 GMT) Full text and rfc822 format available.

This bug report was last modified 3 years and 147 days ago.

Previous Next


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