From: Sean Whitton <spwhitton@spwhitton.name>
To: Juri Linkov <juri@linkov.net>
Cc: 42210@debbugs.gnu.org, dgutov@yandex.ru
Subject: bug#42210: Add -other-window variants of project-prefix-map commands
Date: Sun, 05 Jul 2020 18:58:17 -0700 [thread overview]
Message-ID: <87wo3hflqe.fsf@iris.silentflame.com> (raw)
In-Reply-To: <87k0zhv6kb.fsf@linkov.net>
Hello Juri,
Thanks for taking a look.
On Mon 06 Jul 2020 at 03:19AM +03, Juri Linkov wrote:
>> Here is a patch implementing commands under C-x 4 p. If the approach is
>> thought sound I can also prepare patches for C-x 5 p and C-x t p.
>>
>> I have tested the attached change except for the autoload cookies which
>> I am not sure will work with my new macro. And I'm not sure I should be
>> doing this with a macro instead of a function which calls fset -- please
>> advise.
>
> Thanks for the patch. On emacs-devel you said that rather than add
> definitions of project-find-file-other-window, etc.
> display-buffer-override-next-command could be used. But there is no
> display-buffer-override-next-command in your patch, and definitions of
> project-find-file-other-window etc. are still added (with the help of macro).
Yeah. After thinking about it a bit more I thought that this would be
more consistent with both the way the other C-x 4 commands work and how
the C-x p subcommands work -- i.e., it's just an ordinary keymap.
Additionally, my approach means that the -other-window functions are
available to be called from lisp, just as switch-to-buffer-other-window
and find-file-other-window already are, which might be useful.
From my perspective, the use of define-other-window-command is
sufficient to resolve my concerns (posted to emacs-devel) about having to
define all the functions. And I think that the macro could be useful in
user init files and maybe elsewhere.
> Would it be possible to define the 'C-x 4 p' map the same way as
> 'C-x p p' is defined? There is a patch in https://debbugs.gnu.org/41890#127
> to use the default project keymap 'C-x p' in 'C-x p p'. You could try to
> use the same keymap in 'C-x 4 p', and wrap the command call with
> display-buffer-override-next-command.
I could give it a shot, but wouldn't it be less useful, since the
-other-window functions would no longer be available to be called from
lisp?
As I say, I think the concerns about having to define the functions is
resolved by define-other-window-command (or whatever it ends up called).
Maybe you could explain why you think doing it like C-x p p would be
better. Thanks again.
--
Sean Whitton
next prev parent reply other threads:[~2020-07-06 1:58 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-04 0:54 Add -other-{window,frame} variants of project-prefix-map commands Sean Whitton
2020-07-04 5:34 ` Add -other-{window, frame} " Stephen Leake
2020-07-04 23:24 ` Sean Whitton
2020-07-06 0:58 ` Stephen Leake
2020-07-06 0:23 ` Juri Linkov
2020-07-06 3:31 ` Stefan Monnier
2020-07-06 22:57 ` Juri Linkov
2020-07-06 23:27 ` Drew Adams
2020-07-06 23:35 ` Stefan Monnier
2020-07-07 23:52 ` Juri Linkov
2020-07-08 4:06 ` Stefan Monnier
2020-07-09 0:24 ` Juri Linkov
2020-07-09 23:58 ` Juri Linkov
2020-07-05 6:13 ` bug#42210: Add -other-window " Sean Whitton
2020-07-05 14:41 ` Eli Zaretskii
2020-07-05 18:35 ` Drew Adams
2020-07-05 20:25 ` Sean Whitton
2020-07-06 0:00 ` Drew Adams
2020-07-06 0:19 ` Juri Linkov
2020-07-06 1:58 ` Sean Whitton [this message]
2020-07-06 22:59 ` Juri Linkov
2020-07-08 6:27 ` Sean Whitton
2020-07-09 0:10 ` Juri Linkov
2020-07-11 17:09 ` Sean Whitton
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=87wo3hflqe.fsf@iris.silentflame.com \
--to=spwhitton@spwhitton.name \
--cc=42210@debbugs.gnu.org \
--cc=dgutov@yandex.ru \
--cc=juri@linkov.net \
/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.