; Populate completions list before scrolling it

This fixes a regression introduced in b12a3a03ae, where
repeating a completion command (e.g. TAB in the minibuffer)
would no longer scroll through all available completions.

* lisp/minibuffer.el (completion--in-region-1): Call
'completion--lazy-insert-strings' before scrolling
the completions list.
This commit is contained in:
Eshel Yaron 2025-03-24 16:17:52 +01:00
parent 0cfe700e33
commit 119931a9ce
No known key found for this signature in database
GPG key ID: EF3EE9CA35D78618

View file

@ -1690,6 +1690,7 @@ scroll the window of possible completions."
((eq completion-auto-select 'second-tab))
;; Reverse tab
((equal (this-command-keys) [backtab])
(completion--lazy-insert-strings)
(if (pos-visible-in-window-p (point-min) window)
;; If beginning is in view, scroll up to the end.
(set-window-point window (point-max))
@ -1697,6 +1698,7 @@ scroll the window of possible completions."
(with-selected-window window (scroll-down))))
;; Normal tab
(t
(completion--lazy-insert-strings)
(if (pos-visible-in-window-p (point-max) window)
;; If end is in view, scroll up to the end.
(set-window-start window (point-min) nil)