From: Stefan Monnier <monnier@IRO.UMontreal.CA>
To: dancol@dancol.org
Cc: emacs-devel@gnu.org
Subject: Re: [Emacs-diffs] master 6fdc3fa: Support terminal focus notifications
Date: Sat, 09 Jun 2018 15:05:01 -0400 [thread overview]
Message-ID: <jwvfu1veqhq.fsf-monnier+emacsdiffs@gnu.org> (raw)
In-Reply-To: <c7238f9b25566e4b38c4ca1e119e1d5d.squirrel@dancol.org> (dancol@dancol.org's message of "Sat, 9 Jun 2018 08:49:25 -0700")
> handle-focus-{in,out} have an interactive specification that makes them
> not work when bound directly to the synthetic event --- which seems silly,
> since we never actually use the event --- but I didn't want to touch the
> existing focus code.
Ah, right. We can fix the interactive spec not to signal an error.
>>> +(define-key global-map [xterm-focus-in] #'xterm-handle-focus-in)
>>> +(define-key global-map [xterm-focus-out] #'xterm-handle-focus-out)
>>
>> I think this deserves a comment explaining why we don't use the
>> pre-existing `focus-in` and `focus-out` events and why we bind our
>> events in global-map rather than in special-map (as is done for
>> `focus-in/out` events).
>
> I was being consistent with the xterm-paste event. All three events should
> go in special-map if that's the right place, shouldn't they?
The decision should not be based on the fact that they all come
from xterm. I think xterm-paste wouldn't be right on special-map.
But to tell you the truth, I'm not completely sure what should go on
special-map and what shouldn't.
> It doesn't seem to make a difference in this case.
I think it makes a difference if you do:
C-x <focus-out> <focus-in> C-c
[ My general rule of thumb for special-map is to think about what
should happen if such events happen in the middle of
a key-sequence. ]
Stefan
next prev parent reply other threads:[~2018-06-09 19:05 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20180609055212.3056.85949@vcs0.savannah.gnu.org>
[not found] ` <20180609055213.B7E0920498@vcs0.savannah.gnu.org>
2018-06-09 15:33 ` [Emacs-diffs] master 6fdc3fa: Support terminal focus notifications Stefan Monnier
2018-06-09 15:49 ` dancol
2018-06-09 19:05 ` Stefan Monnier [this message]
2018-06-09 20:19 ` dancol
2018-06-09 23:10 ` Stefan Monnier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=jwvfu1veqhq.fsf-monnier+emacsdiffs@gnu.org \
--to=monnier@iro.umontreal.ca \
--cc=dancol@dancol.org \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.