Emacs: Set company-idle-delay to 0.5 and refactor.

This commit is contained in:
tastytea 2020-03-09 15:18:51 +01:00
parent 65671f96a7
commit b788e7d8f0
1 changed files with 11 additions and 21 deletions

View File

@ -1,6 +1,6 @@
;;; common.el --- Common programming settings. -*- lexical-binding: t; -*-
;; Time-stamp: <2020-02-28T05:05:27+0100>
;; Time-stamp: <2020-03-09T15:18:43+0100>
;;; Commentary:
@ -73,26 +73,16 @@
(unless slow-computer
(use-package company
:diminish company-mode
:custom
;; Show suggestions after entering one character.
(company-minimum-prefix-length 1)
(company-selection-wrap-around t) ; Wrap around at end/beginning of list.
; Align annotation to the right border.
(company-tooltip-align-annotations t)
(company-idle-delay 0) ; No delay.
:bind
(:map company-active-map
("<return>" . nil) ; Disable completion on return.
("RET" . nil) ; https://emacs.stackexchange.com/a/13290
("<tab>" . company-complete-selection) ; Make tab work in lists (GUI).
("TAB" . company-complete-selection) ; Same in terminals.
)
:hook
(after-init . global-company-mode)
)
:custom ((company-minimum-prefix-length 1) ; Suggestions after 1 character.
(company-selection-wrap-around t)
(company-tooltip-align-annotations t) ; Align to the right border.
(company-idle-delay 0.5))
:bind (:map company-active-map
("<return>" . nil) ; Disable completion on return.
("RET" . nil) ; https://emacs.stackexchange.com/a/13290
("<tab>" . company-complete-selection) ; Make tab work in lists.
("TAB" . company-complete-selection)) ; Tab in terminals.
:hook (after-init . global-company-mode))
;; Fuzzy autocompletion for company.
(use-package company-flx