mirror of
https://codeberg.org/scip/dot-emacs.git
synced 2026-11-22 14:18:58 +01:00
fix latex dabbrev completion, enable corfu globally
This commit is contained in:
2
init.el
2
init.el
@@ -139,6 +139,7 @@
|
||||
(require 'init-typst)
|
||||
(require 'init-editorconfig)
|
||||
(require 'init-flymake)
|
||||
(require 'init-latex)
|
||||
|
||||
;; interactive modes
|
||||
(require 'init-eshell)
|
||||
@@ -172,6 +173,7 @@
|
||||
(require 'init-ibuffer)
|
||||
(require 'init-printing)
|
||||
(require 'init-smarter-than-emacs)
|
||||
(require 'init-dabbrev)
|
||||
(require 'init-marginalia)
|
||||
(require 'init-avy)
|
||||
(require 'init-ui)
|
||||
|
||||
8
lisp/init-dabbrev.el
Normal file
8
lisp/init-dabbrev.el
Normal file
@@ -0,0 +1,8 @@
|
||||
;; -*- lexical-binding: nil; -*-
|
||||
|
||||
|
||||
(use-package dabbrev
|
||||
:commands dabbrev-capf)
|
||||
|
||||
|
||||
(provide 'init-dabbrev)
|
||||
18
lisp/init-latex.el
Normal file
18
lisp/init-latex.el
Normal file
@@ -0,0 +1,18 @@
|
||||
;; -*- lexical-binding: nil; -*-
|
||||
|
||||
(setopt text-mode-ispell-word-completion nil)
|
||||
|
||||
(use-package latex
|
||||
:ensure nil
|
||||
|
||||
:mode
|
||||
("\\.tex\\'" . latex-mode)
|
||||
|
||||
:config)
|
||||
|
||||
(add-hook 'latex-mode-hook
|
||||
(lambda ()
|
||||
(add-hook 'completion-at-point-functions #'dabbrev-capf 20 t)))
|
||||
|
||||
|
||||
(provide 'init-latex)
|
||||
@@ -272,7 +272,13 @@ a remote file anytime and from everywhere I am by just entering :"
|
||||
;; clever and nice looking and feeling completion package, candidates
|
||||
;; show up in a mini popup, very nice
|
||||
(use-package corfu
|
||||
:hook ((prog-mode . corfu-mode))
|
||||
:init
|
||||
(global-corfu-mode)
|
||||
|
||||
;; :hook ((prog-mode . corfu-mode)
|
||||
;; (plain-tex-mode . corfu-mode)
|
||||
;; (tex-mode . corfu-mode)
|
||||
;; (latex-mode . corfu-mode))
|
||||
|
||||
:custom
|
||||
(corfu-quit-no-match t)
|
||||
@@ -285,7 +291,7 @@ a remote file anytime and from everywhere I am by just entering :"
|
||||
("TAB" . corfu-next)
|
||||
([tab] . corfu-next)
|
||||
("S-TAB" . corfu-previous)
|
||||
([backtab] . corfu-previous)))
|
||||
([backtab] . corfu-next)))
|
||||
|
||||
|
||||
;; much better experience to seach current buffer, consult-line would
|
||||
|
||||
Reference in New Issue
Block a user