Added Orderless completion Emacs
This commit is contained in:
17
emacs/.emacs.d/lisp/misc/dashboard.el
Normal file
17
emacs/.emacs.d/lisp/misc/dashboard.el
Normal file
@@ -0,0 +1,17 @@
|
||||
;;; dashboard.el --- Startup dashboard -*- lexical-binding: t; -*-
|
||||
|
||||
(use-package dashboard
|
||||
:ensure t
|
||||
:init
|
||||
(setq dashboard-startup-banner 'logo
|
||||
dashboard-center-content t
|
||||
dashboard-set-heading-icons t
|
||||
dashboard-set-file-icons t
|
||||
dashboard-items '((recents . 8)
|
||||
(projects . 5)))
|
||||
:config
|
||||
(dashboard-setup-startup-hook))
|
||||
|
||||
(provide 'dashboard)
|
||||
|
||||
;;; misc-dashboard.el ends here
|
||||
@@ -35,6 +35,29 @@
|
||||
(list "~/.emacs.d/snippets") yas-indent-line 'fixed)
|
||||
(yas-global-mode))
|
||||
|
||||
(use-package orderless
|
||||
:ensure t
|
||||
:custom
|
||||
(completion-styles '(orderless basic))
|
||||
(completion-category-overrides '((file (styles partial-completion))))
|
||||
(completion-pcm-leading-wildcard t)
|
||||
:config
|
||||
(setq ivy-re-builders-alist '((t . orderless-ivy-re-builder)))
|
||||
(add-to-list 'ivy-highlight-functions-alist '(orderless-ivy-re-builder . orderless-ivy-highlight)))
|
||||
|
||||
(defun just-one-face (fn &rest args)
|
||||
(let ((orderless-match-faces [completions-common-part]))
|
||||
(apply fn args)))
|
||||
|
||||
(advice-add 'company-capf--candidates :around #'just-one-face)
|
||||
|
||||
(use-package smartparens
|
||||
:ensure smartparens ;; install the package
|
||||
:hook (prog-mode text-mode markdown-mode) ;; add `smartparens-mode` to these hooks
|
||||
:config
|
||||
;; load default config
|
||||
(require 'smartparens-config))
|
||||
|
||||
(provide 'completion)
|
||||
|
||||
;;; completion.el ends here
|
||||
|
||||
Reference in New Issue
Block a user