Prefix current candidate in Vertico with ":"
This commit is contained in:
parent
eb46c6a277
commit
79eb4dce2b
19
init.el
19
init.el
|
@ -1461,16 +1461,15 @@ if ripgrep is installed, otherwise `consult-grep'."
|
|||
(:also-load vertico-mouse)
|
||||
(vertico-mouse-mode +1)
|
||||
|
||||
;; Workarounds!
|
||||
;; (with-eval-after-load 'org
|
||||
;; (when (version< org-version "9.5")
|
||||
;; (defun disable-selection ()
|
||||
;; (when (eq minibuffer-completion-table #'org-tags-completion-function)
|
||||
;; (setq-local vertico-map minibuffer-local-completion-map
|
||||
;; completion-cycle-threshold nil
|
||||
;; completion-styles '(basic))))
|
||||
;; (advice-add #'vertico--setup :before #'disable-selection)))
|
||||
)
|
||||
;; Prefix the current candidate with ": ". From Vertico wiki.
|
||||
(advice-add #'vertico--format-candidate :around
|
||||
(lambda (orig cand prefix suffix index _start)
|
||||
(setq cand (funcall orig cand prefix suffix index _start))
|
||||
(concat
|
||||
(if (= vertico--index index)
|
||||
(propertize ": " 'face 'vertico-current)
|
||||
" ")
|
||||
cand))))
|
||||
|
||||
(setup (:straight vuiet)
|
||||
(:needs "youtube-dl"
|
||||
|
|
Loading…
Reference in New Issue