* bug#74616: 30.0.92; tmm always displays the *Completions* buffer
@ 2024-11-30 6:42 Daniel Mendler via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-30 8:04 ` Eli Zaretskii
0 siblings, 1 reply; 5+ messages in thread
From: Daniel Mendler via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2024-11-30 6:42 UTC (permalink / raw)
To: 74616; +Cc: Stefan Monnier
The `tmm-add-prompt' function of tmm.el automatically displays the
*Completions* buffer by calling `minibuffer-completion-help'. If an
alternative minibuffer completion system like Icomplete or Vertico is
used, the *Completions* buffer is not needed since the candidates are
already displayed in the minibuffer. I propose to either detect these
alternative completion systems (e.g., by checking the value of the
completing-read-function and/or the mode variables) or to provide a new
customization variable `tmm-display-completions' which defaults to t but
can be set to nil to disable the call to `minibuffer-completion-help'. I
am happy to provide a patch for either of these approaches.
^ permalink raw reply [flat|nested] 5+ messages in thread
* bug#74616: 30.0.92; tmm always displays the *Completions* buffer
2024-11-30 6:42 bug#74616: 30.0.92; tmm always displays the *Completions* buffer Daniel Mendler via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2024-11-30 8:04 ` Eli Zaretskii
2024-11-30 8:12 ` Daniel Mendler via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-30 18:55 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
0 siblings, 2 replies; 5+ messages in thread
From: Eli Zaretskii @ 2024-11-30 8:04 UTC (permalink / raw)
To: Daniel Mendler; +Cc: 74616, monnier
> Cc: Stefan Monnier <monnier@iro.umontreal.ca>
> Date: Sat, 30 Nov 2024 07:42:33 +0100
> From: Daniel Mendler via "Bug reports for GNU Emacs,
> the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
>
> The `tmm-add-prompt' function of tmm.el automatically displays the
> *Completions* buffer by calling `minibuffer-completion-help'. If an
> alternative minibuffer completion system like Icomplete or Vertico is
> used, the *Completions* buffer is not needed since the candidates are
> already displayed in the minibuffer. I propose to either detect these
> alternative completion systems (e.g., by checking the value of the
> completing-read-function and/or the mode variables) or to provide a new
> customization variable `tmm-display-completions' which defaults to t but
> can be set to nil to disable the call to `minibuffer-completion-help'. I
> am happy to provide a patch for either of these approaches.
I think the automatic detection is a better default behavior, but
maybe we could have a variable (not necessarily a defcustom) for users
who would like to have the old behavior.
Stefan, WDYT?
^ permalink raw reply [flat|nested] 5+ messages in thread
* bug#74616: 30.0.92; tmm always displays the *Completions* buffer
2024-11-30 8:04 ` Eli Zaretskii
@ 2024-11-30 8:12 ` Daniel Mendler via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-30 18:55 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
1 sibling, 0 replies; 5+ messages in thread
From: Daniel Mendler via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2024-11-30 8:12 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: 74616, monnier
Eli Zaretskii <eliz@gnu.org> writes:
>> Cc: Stefan Monnier <monnier@iro.umontreal.ca>
>> Date: Sat, 30 Nov 2024 07:42:33 +0100
>> From: Daniel Mendler via "Bug reports for GNU Emacs,
>> the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
>>
>> The `tmm-add-prompt' function of tmm.el automatically displays the
>> *Completions* buffer by calling `minibuffer-completion-help'. If an
>> alternative minibuffer completion system like Icomplete or Vertico is
>> used, the *Completions* buffer is not needed since the candidates are
>> already displayed in the minibuffer. I propose to either detect these
>> alternative completion systems (e.g., by checking the value of the
>> completing-read-function and/or the mode variables) or to provide a new
>> customization variable `tmm-display-completions' which defaults to t but
>> can be set to nil to disable the call to `minibuffer-completion-help'. I
>> am happy to provide a patch for either of these approaches.
>
> I think the automatic detection is a better default behavior, but
> maybe we could have a variable (not necessarily a defcustom) for users
> who would like to have the old behavior.
See also what I wrote on my ffap bug report. It may make sense to
provide some more general mechanism (auto detection, custom variable,
...) in minibuffer.el which could be used by tmm, ffap and other
packages. For example my GNU ELPA package Jinx faces the same problem -
if default completion is used, `minibuffer-completion-help' should be
called to display the candidates immediately, but not for other
completion UIs.
> Stefan, WDYT?
^ permalink raw reply [flat|nested] 5+ messages in thread
* bug#74616: 30.0.92; tmm always displays the *Completions* buffer
2024-11-30 8:04 ` Eli Zaretskii
2024-11-30 8:12 ` Daniel Mendler via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2024-11-30 18:55 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-12-01 4:00 ` Sean Whitton
1 sibling, 1 reply; 5+ messages in thread
From: Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2024-11-30 18:55 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: Daniel Mendler, 74616
> I think the automatic detection is a better default behavior, but
> maybe we could have a variable (not necessarily a defcustom) for users
> who would like to have the old behavior.
> Stefan, WDYT?
I often use the standard UI and I generally don't like this eagerness to
display *Completions*, so I'd either change the code not to auto-display
the buffer (what I have done locally) or at least offer a variable
for that.
So it seems like the war should have 3 settings: always show, never
show, and "guess" (tho maybe we can skip the "guess" option and let the
other completion UIs set the var to nil).
Stefan
^ permalink raw reply [flat|nested] 5+ messages in thread
* bug#74616: 30.0.92; tmm always displays the *Completions* buffer
2024-11-30 18:55 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2024-12-01 4:00 ` Sean Whitton
0 siblings, 0 replies; 5+ messages in thread
From: Sean Whitton @ 2024-12-01 4:00 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: Daniel Mendler, 74616, Stefan Monnier
Hello,
On Sat 30 Nov 2024 at 01:55pm -05, Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" wrote:
> I often use the standard UI and I generally don't like this eagerness to
> display *Completions*, so I'd either change the code not to auto-display
> the buffer (what I have done locally) or at least offer a variable
> for that.
"eagerness to display *Completions*" made me think of this NEWS.30 entry
which is a stopgap compatibility fix that we'd like to improve:
+++
** The "*Completions*" buffer now always accompanies 'icomplete-in-buffer'.
Previously, it was not consistent whether the "*Completions*" buffer would
appear when using 'icomplete-in-buffer'. Now the "*Completions*" buffer
and Icomplete's in-buffer display of possible completions always
appear together. If you would prefer to see only Icomplete's
in-buffer display, and not the "*Completions*" buffer, you can add this
to your init file:
(advice-add 'completion-at-point :after #'minibuffer-hide-completions)
Possibly the resolution of this bug could help there, too.
--
Sean Whitton
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2024-12-01 4:00 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-30 6:42 bug#74616: 30.0.92; tmm always displays the *Completions* buffer Daniel Mendler via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-30 8:04 ` Eli Zaretskii
2024-11-30 8:12 ` Daniel Mendler via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-30 18:55 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-12-01 4:00 ` Sean Whitton
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).