[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/vertico 18fae58 1/6: Fix #4 - Select prompt if `test-co
From: |
Protesilaos Stavrou |
Subject: |
[elpa] externals/vertico 18fae58 1/6: Fix #4 - Select prompt if `test-completion` succeeds for the input |
Date: |
Thu, 8 Apr 2021 11:54:23 -0400 (EDT) |
branch: externals/vertico
commit 18fae58335a3aec5598440fc49f7b15c4613de32
Author: Daniel Mendler <mail@daniel-mendler.de>
Commit: Daniel Mendler <mail@daniel-mendler.de>
Fix #4 - Select prompt if `test-completion` succeeds for the input
Thanks go to @protesilaos for the report and to @oantolin for convincing me
that
the exiting behavior can be improved.
---
vertico.el | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/vertico.el b/vertico.el
index 8f2c45e..0f47f8e 100644
--- a/vertico.el
+++ b/vertico.el
@@ -280,9 +280,15 @@
(>= vertico--index 0)
(nth vertico--index vertico--candidates)))
(idx (seq-position candidates old)))
+ ;; Update index, when kept candidate is found in new candidates
list.
(setq vertico--index idx)
+ ;; Otherwise select the prompt for matching inputs or missing
candidates.
(setq vertico--keep nil
- vertico--index (if candidates 0 -1))))
+ vertico--index
+ (if (or (not candidates)
+ (test-completion input minibuffer-completion-table
+ minibuffer-completion-predicate))
+ -1 0))))
(setq vertico--base base
vertico--input input
vertico--total total
- [elpa] externals/vertico updated (82ed224 -> 1fc43bb), Protesilaos Stavrou, 2021/04/08
- [elpa] externals/vertico 18fae58 1/6: Fix #4 - Select prompt if `test-completion` succeeds for the input,
Protesilaos Stavrou <=
- [elpa] externals/vertico b94e577 3/6: Truncate multi line candidates to a single line, Protesilaos Stavrou, 2021/04/08
- [elpa] externals/vertico 1fc43bb 6/6: Version 0.2, Protesilaos Stavrou, 2021/04/08
- [elpa] externals/vertico 5e5192f 2/6: Improve prompt selection, Protesilaos Stavrou, 2021/04/08
- [elpa] externals/vertico 24fab0b 5/6: Avoid window resizing - ensure that we never show more than 10 lines, Protesilaos Stavrou, 2021/04/08
- [elpa] externals/vertico c9a28d1 4/6: Minor simplifications, Protesilaos Stavrou, 2021/04/08