selectrum: rework setq's for selectrum use-package
- display all candidates that fit, displaying only 15 leaves a gap - move all of them to `:init` since they can be there
This commit is contained in:
parent
8c75e07497
commit
8aea99c770
1 changed files with 3 additions and 6 deletions
|
@ -4,17 +4,15 @@
|
||||||
:hook (doom-first-input . selectrum-mode)
|
:hook (doom-first-input . selectrum-mode)
|
||||||
:init
|
:init
|
||||||
(setq selectrum-display-action nil
|
(setq selectrum-display-action nil
|
||||||
selectrum-num-candidates-displayed 15
|
selectrum-extend-current-candidate-highlight t
|
||||||
selectrum-extend-current-candidate-highlight t)
|
selectrum-fix-vertical-window-height 17
|
||||||
|
selectrum-max-window-height 17)
|
||||||
(when (featurep! +prescient)
|
(when (featurep! +prescient)
|
||||||
(setq completion-styles '(substring partial-completion)))
|
(setq completion-styles '(substring partial-completion)))
|
||||||
:config
|
:config
|
||||||
(setq selectrum-fix-vertical-window-height 17
|
|
||||||
selectrum-max-window-height 17)
|
|
||||||
(defadvice! +selectrum-refresh-on-cycle (&rest _)
|
(defadvice! +selectrum-refresh-on-cycle (&rest _)
|
||||||
:after 'marginalia-cycle
|
:after 'marginalia-cycle
|
||||||
(when (bound-and-true-p selectrum-mode) (selectrum-exhibit)))
|
(when (bound-and-true-p selectrum-mode) (selectrum-exhibit)))
|
||||||
|
|
||||||
(defun +selectrum/backward-updir ()
|
(defun +selectrum/backward-updir ()
|
||||||
"Delete char before or go up directory for file cagetory selectrum buffers."
|
"Delete char before or go up directory for file cagetory selectrum buffers."
|
||||||
(interactive)
|
(interactive)
|
||||||
|
@ -27,7 +25,6 @@
|
||||||
(directory-file-name
|
(directory-file-name
|
||||||
(expand-file-name new-path))))))
|
(expand-file-name new-path))))))
|
||||||
(call-interactively 'backward-delete-char)))
|
(call-interactively 'backward-delete-char)))
|
||||||
|
|
||||||
(map! :map selectrum-minibuffer-map
|
(map! :map selectrum-minibuffer-map
|
||||||
[backspace] #'+selectrum/backward-updir))
|
[backspace] #'+selectrum/backward-updir))
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue