unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#25113: 25.1.90; Stale menu items after switching to a different major mode (or visiting a buffer)
@ 2016-12-04 22:45 Dmitry Gutov
  2016-12-05 15:41 ` Eli Zaretskii
  0 siblings, 1 reply; 11+ messages in thread
From: Dmitry Gutov @ 2016-12-04 22:45 UTC (permalink / raw)
  To: 25113

1. Start 'emacs -Q', and

- In *scratch*, M-x ruby-mode (or python-mode, or probably many others)

OR

- C-x C-f, visit a Ruby file (or, again, probably any other file)

2. See the "Lisp Interaction" menu disappear, and "Ruby" manu appear.

However, the contents of that menu are exactly the same as what was in
"Lisp Interaction".

If I toggle menu-bar-mode off and on, the menu obtains the correct
contents.

I'm also seeing a problem the menu added by a minor mode which appears
blank at first (which is fixed the same way), but let's tackle the more
obvious problem first.

Looking at older versions, the problem is present as far back as 24.3
(with python-mode; ruby-mode didn't have a menu then).

So this is probably caused by a library change, like the GTK version I
have installed.

***

In GNU Emacs 25.1.90.1 (x86_64-pc-linux-gnu, GTK+ Version 3.18.9)
  of 2016-12-04 built on zappa
Repository revision: a3487a8121e408ee07fe019270b3bdeaac0ee960
Windowing system distributor 'The X.Org Foundation', version 11.0.11804000
System Description:	Ubuntu 16.04.1 LTS

Configured features:
XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND GPM DBUS GCONF GSETTINGS
NOTIFY ACL LIBSELINUX GNUTLS LIBXML2 FREETYPE M17N_FLT LIBOTF XFT ZLIB
TOOLKIT_SCROLL_BARS GTK3 X11





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#25113: 25.1.90; Stale menu items after switching to a different major mode (or visiting a buffer)
  2016-12-04 22:45 bug#25113: 25.1.90; Stale menu items after switching to a different major mode (or visiting a buffer) Dmitry Gutov
@ 2016-12-05 15:41 ` Eli Zaretskii
  2016-12-05 16:13   ` Dmitry Gutov
  0 siblings, 1 reply; 11+ messages in thread
From: Eli Zaretskii @ 2016-12-05 15:41 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: 25113

> From: Dmitry Gutov <dgutov@yandex.ru>
> Date: Mon, 5 Dec 2016 00:45:52 +0200
> 
> 1. Start 'emacs -Q', and
> 
> - In *scratch*, M-x ruby-mode (or python-mode, or probably many others)
> 
> OR
> 
> - C-x C-f, visit a Ruby file (or, again, probably any other file)
> 
> 2. See the "Lisp Interaction" menu disappear, and "Ruby" manu appear.
> 
> However, the contents of that menu are exactly the same as what was in
> "Lisp Interaction".

Not reproducible on my system.

> Looking at older versions, the problem is present as far back as 24.3
> (with python-mode; ruby-mode didn't have a menu then).
> 
> So this is probably caused by a library change, like the GTK version I
> have installed.

Most probably.  Can you tell which updates did you do lately?

When you turn on python-mode or ruby-mode, and click on the
problematic menu item ("Ruby" etc.) on the menu bar, do you see
x-menu-bar-open-internal called?





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#25113: 25.1.90; Stale menu items after switching to a different major mode (or visiting a buffer)
  2016-12-05 15:41 ` Eli Zaretskii
@ 2016-12-05 16:13   ` Dmitry Gutov
  2016-12-05 16:27     ` Eli Zaretskii
  0 siblings, 1 reply; 11+ messages in thread
From: Dmitry Gutov @ 2016-12-05 16:13 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 25113

On 05.12.2016 17:41, Eli Zaretskii wrote:

> Not reproducible on my system.

That's too bad. As described menus are pretty broken on my machine. And 
I'm still on an LTS distribution (Ubuntu 16.04), which must have a lot 
of users.

>> So this is probably caused by a library change, like the GTK version I
>> have installed.
>
> Most probably.  Can you tell which updates did you do lately?

None, really. But then again, I have menu-bar-mode turned off most of 
the time.

I've just tried this when working on a feature request to add a menu to 
inf-ruby-mode (third party package).

> When you turn on python-mode or ruby-mode, and click on the
> problematic menu item ("Ruby" etc.) on the menu bar, do you see
> x-menu-bar-open-internal called?

According to 'M-x debug-on-entry', I don't. Should I check that with GDB 
as well?





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#25113: 25.1.90; Stale menu items after switching to a different major mode (or visiting a buffer)
  2016-12-05 16:13   ` Dmitry Gutov
@ 2016-12-05 16:27     ` Eli Zaretskii
  2016-12-05 20:26       ` Dmitry Gutov
  2016-12-05 21:38       ` Stephen Berman
  0 siblings, 2 replies; 11+ messages in thread
From: Eli Zaretskii @ 2016-12-05 16:27 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: 25113

> Cc: 25113@debbugs.gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> Date: Mon, 5 Dec 2016 18:13:36 +0200
> 
> > When you turn on python-mode or ruby-mode, and click on the
> > problematic menu item ("Ruby" etc.) on the menu bar, do you see
> > x-menu-bar-open-internal called?
> 
> According to 'M-x debug-on-entry', I don't. Should I check that with GDB 
> as well?

Yes, I think so: that function is implemented in C.  Set a breakpoint
in Fx_menu_bar_open_internal.

> > Not reproducible on my system.
> 
> That's too bad. As described menus are pretty broken on my machine. And 
> I'm still on an LTS distribution (Ubuntu 16.04), which must have a lot 
> of users.

Does anyone else using GTK+ build see this?





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#25113: 25.1.90; Stale menu items after switching to a different major mode (or visiting a buffer)
  2016-12-05 16:27     ` Eli Zaretskii
@ 2016-12-05 20:26       ` Dmitry Gutov
  2016-12-05 20:58         ` Eli Zaretskii
  2016-12-05 21:38       ` Stephen Berman
  1 sibling, 1 reply; 11+ messages in thread
From: Dmitry Gutov @ 2016-12-05 20:26 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 25113

On 05.12.2016 18:27, Eli Zaretskii wrote:

> Yes, I think so: that function is implemented in C.  Set a breakpoint
> in Fx_menu_bar_open_internal.

I've done that now, and this breakpoint hasn't been hit once during my 
interactions with the menu, before and after switching to ruby-mode, or 
toggling menu-bar-mode off and on afterwards. Here's the full output:

Reading symbols from emacs...done.
SIGINT is used by the debugger.
Are you sure you want to change it? (y or n) [answered Y; input not from 
terminal]
DISPLAY = :0
TERM = xterm-256color
Breakpoint 1 at 0x4ef3a0: file emacs.c, line 353.
Temporary breakpoint 2 at 0x508810: init_sys_modes. (3 locations)
(gdb) b Fx_menu_bar_open_internal
Breakpoint 3 at 0x46cb50: file xmenu.c, line 354.
(gdb) run -Q
Starting program: /home/dgutov/vc/emacs/src/emacs -Q
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7fffe59e7700 (LWP 16065)]
[New Thread 0x7fffe4975700 (LWP 16066)]
[New Thread 0x7fffdfbc0700 (LWP 16067)]
[Thread 0x7fffdfbc0700 (LWP 16067) exited]
[Thread 0x7fffe59e7700 (LWP 16065) exited]
[Thread 0x7ffff7f1bb00 (LWP 16061) exited]
[Inferior 1 (process 16061) exited normally]





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#25113: 25.1.90; Stale menu items after switching to a different major mode (or visiting a buffer)
  2016-12-05 20:26       ` Dmitry Gutov
@ 2016-12-05 20:58         ` Eli Zaretskii
  0 siblings, 0 replies; 11+ messages in thread
From: Eli Zaretskii @ 2016-12-05 20:58 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: 25113

> Cc: 25113@debbugs.gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> Date: Mon, 5 Dec 2016 22:26:40 +0200
> 
> On 05.12.2016 18:27, Eli Zaretskii wrote:
> 
> > Yes, I think so: that function is implemented in C.  Set a breakpoint
> > in Fx_menu_bar_open_internal.
> 
> I've done that now, and this breakpoint hasn't been hit once during my 
> interactions with the menu, before and after switching to ruby-mode, or 
> toggling menu-bar-mode off and on afterwards.

Sorry, I guess I've misunderstood how this stuff works with GTK menus.





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#25113: 25.1.90; Stale menu items after switching to a different major mode (or visiting a buffer)
  2016-12-05 16:27     ` Eli Zaretskii
  2016-12-05 20:26       ` Dmitry Gutov
@ 2016-12-05 21:38       ` Stephen Berman
  2016-12-06 14:45         ` Dmitry Gutov
  1 sibling, 1 reply; 11+ messages in thread
From: Stephen Berman @ 2016-12-05 21:38 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: Dmitry Gutov, 25113

On Mon, 05 Dec 2016 18:27:30 +0200 Eli Zaretskii <eliz@gnu.org> wrote:

>> Cc: 25113@debbugs.gnu.org
>> From: Dmitry Gutov <dgutov@yandex.ru>
>> Date: Mon, 5 Dec 2016 18:13:36 +0200
>> 
[...]
>> > Not reproducible on my system.
>> 
>> That's too bad. As described menus are pretty broken on my machine. And 
>> I'm still on an LTS distribution (Ubuntu 16.04), which must have a lot 
>> of users.
>
> Does anyone else using GTK+ build see this?

I'm using GTK+ Version 3.14.15 and don't see the problem either on my
distribution's build of 25.1 or on fairly recent builds from the
emacs-25 and master branches.

Steve Berman





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#25113: 25.1.90; Stale menu items after switching to a different major mode (or visiting a buffer)
  2016-12-05 21:38       ` Stephen Berman
@ 2016-12-06 14:45         ` Dmitry Gutov
  2016-12-06 15:23           ` Ken Brown
  0 siblings, 1 reply; 11+ messages in thread
From: Dmitry Gutov @ 2016-12-06 14:45 UTC (permalink / raw)
  To: Stephen Berman, Eli Zaretskii; +Cc: 25113

On 05.12.2016 23:38, Stephen Berman wrote:

>> Does anyone else using GTK+ build see this?
>
> I'm using GTK+ Version 3.14.15 and don't see the problem either on my
> distribution's build of 25.1 or on fairly recent builds from the
> emacs-25 and master branches.

Thank you. Anyone with a more recent version of GTK?

I'm seeing the problem with 3.18.9.





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#25113: 25.1.90; Stale menu items after switching to a different major mode (or visiting a buffer)
  2016-12-06 14:45         ` Dmitry Gutov
@ 2016-12-06 15:23           ` Ken Brown
  2020-08-12  0:25             ` Stefan Kangas
  0 siblings, 1 reply; 11+ messages in thread
From: Ken Brown @ 2016-12-06 15:23 UTC (permalink / raw)
  To: Dmitry Gutov, Stephen Berman, Eli Zaretskii; +Cc: 25113

On 12/6/2016 9:45 AM, Dmitry Gutov wrote:
> On 05.12.2016 23:38, Stephen Berman wrote:
>
>>> Does anyone else using GTK+ build see this?
>>
>> I'm using GTK+ Version 3.14.15 and don't see the problem either on my
>> distribution's build of 25.1 or on fairly recent builds from the
>> emacs-25 and master branches.
>
> Thank you. Anyone with a more recent version of GTK?
>
> I'm seeing the problem with 3.18.9.

I can't reproduce the problem with 3.18.9.  Here's my system info:

In GNU Emacs 25.1.90.1 (x86_64-unknown-cygwin, GTK+ Version 3.18.9)
  of 2016-11-29 built on APPVYR-WIN
Windowing system distributor 'The Cygwin/X Project', version 11.0.11804000

Configured features:
XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND DBUS GSETTINGS NOTIFY ACL
GNUTLS LIBXML2 FREETYPE XFT ZLIB TOOLKIT_SCROLL_BARS GTK3 X11

Ken





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#25113: 25.1.90; Stale menu items after switching to a different major mode (or visiting a buffer)
  2016-12-06 15:23           ` Ken Brown
@ 2020-08-12  0:25             ` Stefan Kangas
  2020-08-12  9:54               ` Dmitry Gutov
  0 siblings, 1 reply; 11+ messages in thread
From: Stefan Kangas @ 2020-08-12  0:25 UTC (permalink / raw)
  To: Ken Brown; +Cc: Stephen Berman, Dmitry Gutov, 25113

Dmitry Gutov <dgutov@yandex.ru> writes:

> 1. Start 'emacs -Q', and
>
> - In *scratch*, M-x ruby-mode (or python-mode, or probably many others)
>
> OR
>
> - C-x C-f, visit a Ruby file (or, again, probably any other file)
>
> 2. See the "Lisp Interaction" menu disappear, and "Ruby" manu appear.
>
> However, the contents of that menu are exactly the same as what was in
> "Lisp Interaction".

Ken Brown <kbrown@cornell.edu> writes:

> On 12/6/2016 9:45 AM, Dmitry Gutov wrote:
>> On 05.12.2016 23:38, Stephen Berman wrote:
>>
>>>> Does anyone else using GTK+ build see this?
>>>
>>> I'm using GTK+ Version 3.14.15 and don't see the problem either on my
>>> distribution's build of 25.1 or on fairly recent builds from the
>>> emacs-25 and master branches.
>>
>> Thank you. Anyone with a more recent version of GTK?
>>
>> I'm seeing the problem with 3.18.9.
>
> I can't reproduce the problem with 3.18.9.  Here's my system info:

I can't reproduce this bug here, using:

GNU Emacs 28.0.50 (build 6, x86_64-pc-linux-gnu, GTK+ Version 3.24.20,
cairo version 1.16.0) of 2020-08-11

Are you still seeing this?

Best regards,
Stefan Kangas





^ permalink raw reply	[flat|nested] 11+ messages in thread

* bug#25113: 25.1.90; Stale menu items after switching to a different major mode (or visiting a buffer)
  2020-08-12  0:25             ` Stefan Kangas
@ 2020-08-12  9:54               ` Dmitry Gutov
  0 siblings, 0 replies; 11+ messages in thread
From: Dmitry Gutov @ 2020-08-12  9:54 UTC (permalink / raw)
  To: Stefan Kangas, Ken Brown; +Cc: 25113-done, Stephen Berman

On 12.08.2020 03:25, Stefan Kangas wrote:
> I can't reproduce this bug here, using:
> 
> GNU Emacs 28.0.50 (build 6, x86_64-pc-linux-gnu, GTK+ Version 3.24.20,
> cairo version 1.16.0) of 2020-08-11
> 
> Are you still seeing this?

Nope. Same GTK+ version as yours, don't see it either anymore.

It might still be present with the version I was using 4 years ago, but 
if fixing it wasn't a priority back then, it certainly isn't now.

Let's close this.





^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2020-08-12  9:54 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-12-04 22:45 bug#25113: 25.1.90; Stale menu items after switching to a different major mode (or visiting a buffer) Dmitry Gutov
2016-12-05 15:41 ` Eli Zaretskii
2016-12-05 16:13   ` Dmitry Gutov
2016-12-05 16:27     ` Eli Zaretskii
2016-12-05 20:26       ` Dmitry Gutov
2016-12-05 20:58         ` Eli Zaretskii
2016-12-05 21:38       ` Stephen Berman
2016-12-06 14:45         ` Dmitry Gutov
2016-12-06 15:23           ` Ken Brown
2020-08-12  0:25             ` Stefan Kangas
2020-08-12  9:54               ` Dmitry Gutov

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).