blob: cc8f2d3c9662b472ff1a342802ffa4323380fc9e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
(use-package corfu
:ensure t
:hook (after-init . global-corfu-mode)
:bind (:map corfu-map ("<tab>" . corfu-complete))
:config
(setq tab-always-indent 'complete)
(setq corfu-preview-current nil)
(setq corfu-min-width 20)
(setq corfu-popupinfo-delay '(1.25 . 0.5))
(corfu-popupinfo-mode 1)
;; Sort by input history (no need to modify `corfu-sort-function').
(with-eval-after-load 'savehist
(corfu-history-mode 1)
(add-to-list 'savehist-additional-variables 'corfu-history)))
(use-package completion-preview
:diminish
:demand t
:bind
( :map completion-preview-active-mode-map
("M-n" . completion-preview-next-candidate)
("M-p" . completion-preview-prev-candidate)
("<tab>" . completion-preview-insert)
("M-<return>" . completion-preview-insert))
:config
(global-completion-preview-mode)
:custom
(completion-preview-minimum-symbol-length 2)
(completion-preview-ignore-case t))
(use-package cape
:ensure t
:demand t
:init
(add-hook 'completion-at-point-functions #'cape-dabbrev)
(add-hook 'completion-at-point-functions #'cape-file)
:config
(advice-add 'eglot-completion-at-point :around #'cape-wrap-buster))
(setq completion-auto-help nil)
|