From: sbaugh@catern.com
To: Juri Linkov <juri@linkov.net>
Cc: 68801@debbugs.gnu.org, Spencer Baugh <sbaugh@janestreet.com>
Subject: bug#68801: 30.0.50; minibuffer-visible-completions=t makes RET in completion-in-region a no-op with nothing selected
Date: Sat, 10 Feb 2024 18:14:26 +0000 (UTC) [thread overview]
Message-ID: <871q9k6vfo.fsf@catern.com> (raw)
In-Reply-To: <867cjejfan.fsf@mail.linkov.net> (Juri Linkov's message of "Fri, 09 Feb 2024 09:17:20 +0200")
Juri Linkov <juri@linkov.net> writes:
>>> Here's a simple patch: What if minibuffer-visible-completions just only
>>> overrides RET when there's a selected completion? See below. Could
>>> this make sense?
>>
>> Yes, this makes sense. I'll try your patch for a while.
>
> Thanks for the patch, it works nicely.
>
> Could you please write a commit message for this patch.
The annoying thing is that this breaks the enhancement to
completion-show-help I recently made. When a completion is not
selected, RET isn't bound, so the help shows "Click or type M-x
minibuffer-choose-completion-or-exit on a completion to select it."
I'm not sure the right way to fix that. Selectively binding RET based
on whether a completion is selected feels sketchy anyway, it may confuse
users because e.g. C-h c RET won't work.
Maybe instead we should always bind RET, but if no completion is
selected, we run the command that RET was bound to before
completion-in-region-mode started?
Alternatively... as a completely separate point, I'd like
completion-in-region to select the first completion candidate by
default. I think that's useful in some cases and, for
completion-in-region, doesn't have any negatives: we couldn't do it in
the minibuffer because it would interfere with accepting the default,
but there are no defaults in completion-in-region.
If we make c-i-r select the first completion candidate by default, that
would both:
- Make the completion-show-help help render correctly with the "only
override RET when there's a selected completion" patch.
- Partially mitigate the RET issue all on its own
Wdyt?
next prev parent reply other threads:[~2024-02-10 18:14 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-29 18:49 bug#68801: 30.0.50; minibuffer-visible-completions=t makes RET in completion-in-region a no-op with nothing selected Spencer Baugh
2024-01-30 17:28 ` Juri Linkov
2024-01-30 20:21 ` Spencer Baugh
2024-01-31 7:58 ` Juri Linkov
2024-02-09 7:17 ` Juri Linkov
2024-02-10 18:14 ` sbaugh [this message]
2024-02-11 17:59 ` Juri Linkov
2024-02-11 21:02 ` sbaugh
2024-02-16 14:34 ` Spencer Baugh
2024-02-18 7:46 ` Juri Linkov
2024-02-26 16:04 ` Spencer Baugh
2024-02-27 20:45 ` Spencer Baugh
2024-02-29 17:56 ` Juri Linkov
2024-03-15 7:41 ` Juri Linkov
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=871q9k6vfo.fsf@catern.com \
--to=sbaugh@catern.com \
--cc=68801@debbugs.gnu.org \
--cc=juri@linkov.net \
--cc=sbaugh@janestreet.com \
/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 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).