* bug#788: menu indications of key bindings for remapped commands
@ 2009-03-15 18:00 Chong Yidong
2009-03-15 19:33 ` Drew Adams
2009-03-16 0:59 ` Stefan Monnier
0 siblings, 2 replies; 15+ messages in thread
From: Chong Yidong @ 2009-03-15 18:00 UTC (permalink / raw)
To: 788
> As described in:
>
> http://lists.gnu.org/archive/html/emacs-devel/2007-05/msg01020.html
>
> key bindings defined via remap look odd in menus.
I changed the code so that [remap foo] commands are not displayed in the
menus.
Ideally, we would follow the remappings, but I think this could mess up
the menu cache (e.g., if the remapped-to command is rebound). So that's
a larger, post-release project.
^ permalink raw reply [flat|nested] 15+ messages in thread
* bug#788: menu indications of key bindings for remapped commands
2009-03-15 18:00 bug#788: menu indications of key bindings for remapped commands Chong Yidong
@ 2009-03-15 19:33 ` Drew Adams
2009-03-16 1:16 ` Chong Yidong
2009-03-16 0:59 ` Stefan Monnier
1 sibling, 1 reply; 15+ messages in thread
From: Drew Adams @ 2009-03-15 19:33 UTC (permalink / raw)
To: 'Chong Yidong', 788; +Cc: Richard Stallman
> From: Chong Yidong Sent: Sunday, March 15, 2009 11:00 AM
> > As described in:
> > http://lists.gnu.org/archive/html/emacs-devel/2007-05/msg01020.html
> > key bindings defined via remap look odd in menus.
>
> I changed the code so that [remap foo] commands are not
> displayed in the menus.
>
> Ideally, we would follow the remappings, but I think this
> could mess up the menu cache (e.g., if the remapped-to
> command is rebound). So that's a larger, post-release project.
I haven't tried after your fix, but from your description of the fix, (a) the
bug is not fixed at all, and (b) the change is negative.
1. It is inappropriate to *remove* such commands (menu items) from the menu. Or
did you mean just remove the confusing key bindings from the menu items?
The latter would be OK as a temporary workaround, but it represents a loss of
information, and it does not fix the bug. To fix the bug, the real, user-level
key binding needs to be shown.
2. The bug needs to be fixed properly, as Richard requested two years ago. It's
inappropriate to just close it now with a statement that we are too close to the
release to fix it properly.
The goal should be to improve Emacs by fixing bugs, not simply to reduce the bug
count by closing bugs without fixing them.
If you want to keep this bug open and fix it sometime after the release, that
would be appropriate, but closing it with a non-fix fix is inappropriate.
^ permalink raw reply [flat|nested] 15+ messages in thread
* bug#788: menu indications of key bindings for remapped commands
2009-03-15 19:33 ` Drew Adams
@ 2009-03-16 1:16 ` Chong Yidong
2009-03-16 1:51 ` Drew Adams
0 siblings, 1 reply; 15+ messages in thread
From: Chong Yidong @ 2009-03-16 1:16 UTC (permalink / raw)
To: Drew Adams; +Cc: 788, Richard Stallman
"Drew Adams" <drew.adams@oracle.com> writes:
> The goal should be to improve Emacs by fixing bugs, not simply to
> reduce the bug count by closing bugs without fixing them.
>
> If you want to keep this bug open and fix it sometime after the
> release, that would be appropriate, but closing it with a non-fix fix
> is inappropriate.
This bug is still open. Spare me the lecture on bug management.
^ permalink raw reply [flat|nested] 15+ messages in thread
* bug#788: menu indications of key bindings for remapped commands
2009-03-16 1:16 ` Chong Yidong
@ 2009-03-16 1:51 ` Drew Adams
2009-03-16 2:11 ` Chong Yidong
0 siblings, 1 reply; 15+ messages in thread
From: Drew Adams @ 2009-03-16 1:51 UTC (permalink / raw)
To: 'Chong Yidong'; +Cc: 788, 'Richard Stallman'
> From: Chong Yidong Sent: Sunday, March 15, 2009 6:17 PM
> This bug is still open. Spare me the lecture on bug management.
Keeping the bug open is good. Thanks.
How about the question wrt what change was actually made?
> > I changed the code so that [remap foo] commands are not
> > displayed in the menus.
>
> 1. It is inappropriate to *remove* such commands (menu items)
> from the menu. Or did you mean just remove the confusing key
> bindings from the menu items?
You didn't confirm or deny whether you in fact removed the items from the menu
(as you said) or just removed the key bindings (which would be OK as temporary
workaround).
If you did as you said, then please revert your change. It is more important to
keep the menu items, even if their key-binding mentions are not yet ideal.
^ permalink raw reply [flat|nested] 15+ messages in thread
* bug#788: menu indications of key bindings for remapped commands
2009-03-16 1:51 ` Drew Adams
@ 2009-03-16 2:11 ` Chong Yidong
2009-03-16 3:20 ` Drew Adams
0 siblings, 1 reply; 15+ messages in thread
From: Chong Yidong @ 2009-03-16 2:11 UTC (permalink / raw)
To: Drew Adams; +Cc: 788, 'Richard Stallman'
"Drew Adams" <drew.adams@oracle.com> writes:
>> > I changed the code so that [remap foo] commands are not
>> > displayed in the menus.
>>
>> 1. It is inappropriate to *remove* such commands (menu items)
>> from the menu. Or did you mean just remove the confusing key
>> bindings from the menu items?
>
> You didn't confirm or deny whether you in fact removed the items from
> the menu (as you said) or just removed the key bindings (which would
> be OK as temporary workaround).
The latter.
^ permalink raw reply [flat|nested] 15+ messages in thread
* bug#788: menu indications of key bindings for remapped commands
2009-03-16 2:11 ` Chong Yidong
@ 2009-03-16 3:20 ` Drew Adams
0 siblings, 0 replies; 15+ messages in thread
From: Drew Adams @ 2009-03-16 3:20 UTC (permalink / raw)
To: 'Chong Yidong'; +Cc: 788, 'Richard Stallman'
> >> > I changed the code so that [remap foo] commands are not
> >> > displayed in the menus.
> >>
> >> 1. It is inappropriate to *remove* such commands (menu items)
> >> from the menu. Or did you mean just remove the confusing key
> >> bindings from the menu items?
> >
> > You didn't confirm or deny whether you in fact removed the
> > items from the menu (as you said) or just removed the key
> > bindings (which would be OK as temporary workaround).
>
> The latter.
Great, thanks. And thanks for clearing that up.
^ permalink raw reply [flat|nested] 15+ messages in thread
* bug#788: menu indications of key bindings for remapped commands
2009-03-15 18:00 bug#788: menu indications of key bindings for remapped commands Chong Yidong
2009-03-15 19:33 ` Drew Adams
@ 2009-03-16 0:59 ` Stefan Monnier
2009-03-16 1:34 ` Chong Yidong
1 sibling, 1 reply; 15+ messages in thread
From: Stefan Monnier @ 2009-03-16 0:59 UTC (permalink / raw)
To: Chong Yidong; +Cc: 788
> Ideally, we would follow the remappings, but I think this could mess up
> the menu cache (e.g., if the remapped-to command is rebound).
What menu cache? AFAIK the keybindings shown in menus are not cached
any more.
Stefan
^ permalink raw reply [flat|nested] 15+ messages in thread
* bug#788: menu indications of key bindings for remapped commands
2009-03-16 0:59 ` Stefan Monnier
@ 2009-03-16 1:34 ` Chong Yidong
2009-03-16 3:01 ` Stefan Monnier
0 siblings, 1 reply; 15+ messages in thread
From: Chong Yidong @ 2009-03-16 1:34 UTC (permalink / raw)
To: Stefan Monnier; +Cc: 788
Stefan Monnier <monnier@iro.umontreal.ca> writes:
>> Ideally, we would follow the remappings, but I think this could mess up
>> the menu cache (e.g., if the remapped-to command is rebound).
>
> What menu cache? AFAIK the keybindings shown in menus are not cached
> any more.
I meant the where_is_cache, which currently stores such keybindings as
[remap foo]. In parse_menu_item, we call Fwhere_is_internal, which
consults the cache and gets this result. The cache is consulted because
the `firstonly' argument for this call is `t', which causes
Fwhere_is_internal to consult the cache; if it's nil, Fwhere_is_internal
does not use the cache.
^ permalink raw reply [flat|nested] 15+ messages in thread
* bug#788: menu indications of key bindings for remapped commands
2009-03-16 1:34 ` Chong Yidong
@ 2009-03-16 3:01 ` Stefan Monnier
2009-03-16 15:30 ` Chong Yidong
0 siblings, 1 reply; 15+ messages in thread
From: Stefan Monnier @ 2009-03-16 3:01 UTC (permalink / raw)
To: Chong Yidong; +Cc: 788
>>> Ideally, we would follow the remappings, but I think this could mess up
>>> the menu cache (e.g., if the remapped-to command is rebound).
>> What menu cache? AFAIK the keybindings shown in menus are not cached
>> any more.
> I meant the where_is_cache, which currently stores such keybindings as
> [remap foo].
I see, yes, this cache. But then I don't see what problem you're
thining of.
BTW, shouldn't this remap-handling be done in Fwhere_is_internal rather
than in parse_menu_item?
Stefan
^ permalink raw reply [flat|nested] 15+ messages in thread
* bug#788: menu indications of key bindings for remapped commands
2009-03-16 3:01 ` Stefan Monnier
@ 2009-03-16 15:30 ` Chong Yidong
2009-03-16 19:27 ` Stefan Monnier
0 siblings, 1 reply; 15+ messages in thread
From: Chong Yidong @ 2009-03-16 15:30 UTC (permalink / raw)
To: Stefan Monnier; +Cc: 788
Stefan Monnier <monnier@iro.umontreal.ca> writes:
> BTW, shouldn't this remap-handling be done in Fwhere_is_internal
> rather than in parse_menu_item?
So, the idea is for Fwhere_is_internal to extract the cache entry (which
has the form [remap foo]), and follow the remapping before returning the
value to its caller?
Yeah, that might work, though I don't know how much existing code
depends on the current behavior.
^ permalink raw reply [flat|nested] 15+ messages in thread
* bug#788: menu indications of key bindings for remapped commands
2009-03-16 15:30 ` Chong Yidong
@ 2009-03-16 19:27 ` Stefan Monnier
2010-01-22 18:17 ` Drew Adams
0 siblings, 1 reply; 15+ messages in thread
From: Stefan Monnier @ 2009-03-16 19:27 UTC (permalink / raw)
To: Chong Yidong; +Cc: 788
>> BTW, shouldn't this remap-handling be done in Fwhere_is_internal
>> rather than in parse_menu_item?
> So, the idea is for Fwhere_is_internal to extract the cache entry (which
> has the form [remap foo]), and follow the remapping before returning the
> value to its caller?
Well, the behavior equivalent to your current code would be to return
nil, but yes, it could also try to "reverse-remap" the command back to
a key binding (being careful to try and avoid infinite cycles).
> Yeah, that might work, though I don't know how much existing code
> depends on the current behavior.
Good point. Let's leave it in parse_menu_item for now, but revisit
it later.
Stefan
^ permalink raw reply [flat|nested] 15+ messages in thread
* bug#788: menu indications of key bindings for remapped commands
2009-03-16 19:27 ` Stefan Monnier
@ 2010-01-22 18:17 ` Drew Adams
2010-01-25 2:53 ` Stefan Monnier
0 siblings, 1 reply; 15+ messages in thread
From: Drew Adams @ 2010-01-22 18:17 UTC (permalink / raw)
To: 'Stefan Monnier', 788, 'Chong Yidong'
This bug is still open.
Also, there is a regression. Yidong's temporary workaround of removing the key
reminder from the menu item no longer applies to the pretest: the <remap> <...>
key reminder has returned.
In GNU Emacs 23.1.91.1 (i386-mingw-nt5.1.2600)
of 2010-01-02 on PRETEST
Windowing system distributor `Microsoft Corp.', version 5.1.2600
configured using `configure --with-gcc (3.4)'
A proper fix that shows the correct key (vs shows no key) is still needed.
^ permalink raw reply [flat|nested] 15+ messages in thread
end of thread, other threads:[~2010-01-25 5:22 UTC | newest]
Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-03-15 18:00 bug#788: menu indications of key bindings for remapped commands Chong Yidong
2009-03-15 19:33 ` Drew Adams
2009-03-16 1:16 ` Chong Yidong
2009-03-16 1:51 ` Drew Adams
2009-03-16 2:11 ` Chong Yidong
2009-03-16 3:20 ` Drew Adams
2009-03-16 0:59 ` Stefan Monnier
2009-03-16 1:34 ` Chong Yidong
2009-03-16 3:01 ` Stefan Monnier
2009-03-16 15:30 ` Chong Yidong
2009-03-16 19:27 ` Stefan Monnier
2010-01-22 18:17 ` Drew Adams
2010-01-25 2:53 ` Stefan Monnier
2010-01-25 5:05 ` Drew Adams
2010-01-25 5:22 ` Drew Adams
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.