diff options
| author | Daniel Mendler <mail@daniel-mendler.de> | 2023-09-30 21:20:55 +0200 |
|---|---|---|
| committer | Daniel Mendler <mail@daniel-mendler.de> | 2023-09-30 21:20:55 +0200 |
| commit | 4da6c58b777b9aedfc5960f5ce492a03745f3042 (patch) | |
| tree | 6e2300f38fc41503201db974fc35989e6e752e4b /extensions | |
| parent | 048c1e09c1fe8807d54e3733abe78e4308c017c1 (diff) | |
corfu-quick: Support more candidates
See also https://github.com/minad/vertico/commit/5c9a4af57b38fb1a6e78d3e23d50fc59b951241d
Diffstat (limited to 'extensions')
| -rw-r--r-- | extensions/corfu-quick.el | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/extensions/corfu-quick.el b/extensions/corfu-quick.el index fdfa333..f4014d2 100644 --- a/extensions/corfu-quick.el +++ b/extensions/corfu-quick.el @@ -45,7 +45,7 @@ :type 'string :group 'corfu) -(defcustom corfu-quick2 "jkl" +(defcustom corfu-quick2 "jkluionm" "Second level quick keys." :type 'string :group 'corfu) @@ -72,12 +72,11 @@ "Format quick keys prefix. IDX is the current candidate index. TWO is non-nil if two keys should be displayed." - (let* ((fst (length corfu-quick1)) - (snd (length corfu-quick2)) - (len (+ fst snd))) + (let ((fst (length corfu-quick1)) + (snd (length corfu-quick2))) (if (>= idx fst) - (let ((first (elt corfu-quick2 (mod (/ (- idx fst) len) snd))) - (second (elt (concat corfu-quick1 corfu-quick2) (mod (- idx fst) len)))) + (let ((first (elt corfu-quick2 (mod (/ (- idx fst) fst) snd))) + (second (elt corfu-quick1 (mod (- idx fst) fst)))) (cond ((eq first two) (list |
