Subject: Re: bug#47699: [PATCH] Improve completion-list-mode-map

From: Juri Linkov <[email-masked]>
Date: Mon, 12 Apr 2021 01:36:10 +0300

>>> Well, vanilla Emacs defines M-v = switch-to-completions, which opens
>>> *Completions* and makes it the current buffer.  In a selection-like
>>> scenario, it makes sense to switch to the completions buffer where you
>>> can freely move around, use isearch, and so forth.
>>
>> I wonder how many people use this paradigm
>
> I do, from time to time.  I'd be surprised if I were the only one, as
> I remember that it's something I already did during the first days I used
> Emacs.  When you see a window with lots of information appearing, is it not
> natural to enter that window and to move around?

I use this all the time: type PgUp to switch to the completions buffer,
then use the same key PgUp together with PgDn to scroll completions,
and use isearch to search in completions.

The existing useful key 'q' closes the completions buffer,
and switches back to the minibuffer.

But then I have such customization, with it using the completions buffer
is more handy:

(defun choose-completion-no-auto-exit ()
  (interactive)
  (let ((completion-no-auto-exit t))
    (call-interactively 'choose-completion)))

(define-key completion-list-mode-map [M-return] 'choose-completion-no-auto-exit)

where M-RET inserts the selected completion to the minibuffer without exiting it,
and switches back to the minibuffer.