* ignore is bound to <lwindow> but <lwindow> is META
@ 2006-04-03 16:59 Lennart Borgman
2006-04-03 18:05 ` Stefan Monnier
2006-04-03 18:08 ` Jason Rumney
0 siblings, 2 replies; 7+ messages in thread
From: Lennart Borgman @ 2006-04-03 16:59 UTC (permalink / raw)
This is maybe w32 specific, I am not sure.
I have bound <lwindow> to META but `describe-function' says `ignore' is
still bound to <lwindow>. What is wrong? Am I overlooking something?
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: ignore is bound to <lwindow> but <lwindow> is META
2006-04-03 16:59 ignore is bound to <lwindow> but <lwindow> is META Lennart Borgman
@ 2006-04-03 18:05 ` Stefan Monnier
2006-04-03 18:08 ` Jason Rumney
1 sibling, 0 replies; 7+ messages in thread
From: Stefan Monnier @ 2006-04-03 18:05 UTC (permalink / raw)
Cc: Emacs Devel
> I have bound <lwindow> to META but `describe-function' says `ignore' is
> still bound to <lwindow>. What is wrong? Am I overlooking something?
What makes you think something's wrong? The two notions of "bound" are
different, so I don't see any obvious conflict.
Stefan
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: ignore is bound to <lwindow> but <lwindow> is META
2006-04-03 16:59 ignore is bound to <lwindow> but <lwindow> is META Lennart Borgman
2006-04-03 18:05 ` Stefan Monnier
@ 2006-04-03 18:08 ` Jason Rumney
2006-04-03 18:22 ` Lennart Borgman
1 sibling, 1 reply; 7+ messages in thread
From: Jason Rumney @ 2006-04-03 18:08 UTC (permalink / raw)
Cc: Emacs Devel
Lennart Borgman <lennart.borgman.073@student.lu.se> writes:
> This is maybe w32 specific, I am not sure.
>
> I have bound <lwindow> to META but `describe-function' says `ignore'
> is still bound to <lwindow>. What is wrong? Am I overlooking
> something?
What do you mean when you say you bound lwindow to META?
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: ignore is bound to <lwindow> but <lwindow> is META
2006-04-03 18:08 ` Jason Rumney
@ 2006-04-03 18:22 ` Lennart Borgman
2006-04-03 19:33 ` Stefan Monnier
0 siblings, 1 reply; 7+ messages in thread
From: Lennart Borgman @ 2006-04-03 18:22 UTC (permalink / raw)
Cc: Stefan Monnier, Emacs Devel
Jason Rumney wrote:
> Lennart Borgman <lennart.borgman.073@student.lu.se> writes:
>
>
>> This is maybe w32 specific, I am not sure.
>>
>> I have bound <lwindow> to META but `describe-function' says `ignore'
>> is still bound to <lwindow>. What is wrong? Am I overlooking
>> something?
>>
>
> What do you mean when you say you bound lwindow to META?
>
Sorry for my bad wordings. I do something like this:
(when lwindow-meta
(setq w32-lwindow-modifier 'meta)
(setq w32-pass-lwindow-to-system nil))
This is in my w32-meta.el (that uses my patch for the low level keyboard
hook, but that is another story). Maybe I just ought just to add
(global-unset-key [(lwindow)])
at least to be more consistent? On the other hand I do not think that
Emacs should say that a key is bound to anything if it is used as META.
But I am a bit confused here so I appreciate explanations!
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: ignore is bound to <lwindow> but <lwindow> is META
2006-04-03 18:22 ` Lennart Borgman
@ 2006-04-03 19:33 ` Stefan Monnier
2006-04-03 19:52 ` Lennart Borgman
0 siblings, 1 reply; 7+ messages in thread
From: Stefan Monnier @ 2006-04-03 19:33 UTC (permalink / raw)
Cc: Emacs Devel, Jason Rumney
> at least to be more consistent? On the other hand I do not think that
> Emacs should say that a key is bound to anything if it is used as META.
It's more general than that: When Emacs says "foo is bound to M-c, <prior>,
<S-C-mouse-3>" all it means is that if you somehow manage to generate events
M-c, <prior> or <S-C-mouse-3>, then that'll call those functions.
But M-c may be remapped via key-translation-map to something else, so
hitting Meta+c may not actually call your function `foo'.
And the key that you think of as "prior" may not send the event <prior>.
Think of the RET vs `return' case.
Even after your (setq w32-lwindow-modifier 'meta), you may still be able to
generate `lwindow' event (using some other key(combo)).
Stefan
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: ignore is bound to <lwindow> but <lwindow> is META
2006-04-03 19:33 ` Stefan Monnier
@ 2006-04-03 19:52 ` Lennart Borgman
2006-04-03 20:29 ` Stefan Monnier
0 siblings, 1 reply; 7+ messages in thread
From: Lennart Borgman @ 2006-04-03 19:52 UTC (permalink / raw)
Cc: Emacs Devel, Jason Rumney
Stefan Monnier wrote:
>> at least to be more consistent? On the other hand I do not think that
>> Emacs should say that a key is bound to anything if it is used as META.
>>
>
> It's more general than that: When Emacs says "foo is bound to M-c, <prior>,
> <S-C-mouse-3>" all it means is that if you somehow manage to generate events
> M-c, <prior> or <S-C-mouse-3>, then that'll call those functions.
>
> But M-c may be remapped via key-translation-map to something else, so
> hitting Meta+c may not actually call your function `foo'.
>
> And the key that you think of as "prior" may not send the event <prior>.
> Think of the RET vs `return' case.
>
> Even after your (setq w32-lwindow-modifier 'meta), you may still be able to
> generate `lwindow' event (using some other key(combo)).
>
>
> Stefan
>
Oh, I see. But is not that quite confusing? There might be many ways to
generate an event (I actually do not know), but when I see "foo is bound
to M-c, ..." I believe that when I hit M-c Emacs will call foo. I
suspect most users will expect the same.
Is not key-translation-map a simple case? Can't this be checked in help?
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: ignore is bound to <lwindow> but <lwindow> is META
2006-04-03 19:52 ` Lennart Borgman
@ 2006-04-03 20:29 ` Stefan Monnier
0 siblings, 0 replies; 7+ messages in thread
From: Stefan Monnier @ 2006-04-03 20:29 UTC (permalink / raw)
Cc: Emacs Devel, Jason Rumney
> Oh, I see. But is not that quite confusing?
Yes, I wouldn't call it a feature. But more generally, figuring out the
reverse mapping from a command (or an event) to its possible sources
(e.g. which physical key (with its name), or mouse movement) is between
difficult and impossible.
> There might be many ways to generate an event (I actually do not know),
> but when I see "foo is bound to M-c, ..." I believe that when I hit M-c
> Emacs will call foo. I suspect most users will expect the same.
> Is not key-translation-map a simple case?
Partly. It's relatively easy to check whether M-c will be affected or not
by key-translation-map, but it can be very hard to determine if
key-translation-map can translate some other event into M-c.
> Can't this be checked in help?
It could. And it might get us one step closer. But there are still many
more steps, some of which outside of Emacs's control and/or knowledge, and
additional steps get added every once in a while, sometimes without even
being aware of it.
Even without key-translation-map, the window-manager might catch the M-c
before Emacs sees it, or it might be bound via special-event-map, or ...
Stefan
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2006-04-03 20:29 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-04-03 16:59 ignore is bound to <lwindow> but <lwindow> is META Lennart Borgman
2006-04-03 18:05 ` Stefan Monnier
2006-04-03 18:08 ` Jason Rumney
2006-04-03 18:22 ` Lennart Borgman
2006-04-03 19:33 ` Stefan Monnier
2006-04-03 19:52 ` Lennart Borgman
2006-04-03 20:29 ` Stefan Monnier
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).