Add Company mode
This commit is contained in:
parent
6c7958f1f2
commit
94aad9cdb4
2 changed files with 18 additions and 1 deletions
|
@ -15,6 +15,7 @@
|
|||
(depends-on "circe")
|
||||
(depends-on "clojure-mode")
|
||||
(depends-on "coffee-mode")
|
||||
(depends-on "company")
|
||||
(depends-on "corral")
|
||||
(depends-on "csharp-mode")
|
||||
(depends-on "css-eldoc")
|
||||
|
|
|
@ -190,6 +190,13 @@ MODE1 is enabled and vice-versa."
|
|||
(with-eval-after-load 'cc-mode
|
||||
(define-key c-mode-map (kbd "<f9>") 'compile))
|
||||
|
||||
(stante-after company
|
||||
(setq company-frontends
|
||||
'(company-pseudo-tooltip-unless-just-one-frontend
|
||||
company-echo-metadata-frontend
|
||||
company-preview-frontend))
|
||||
(setq company-idle-delay 0.2))
|
||||
|
||||
(stante-after compile
|
||||
(setq compilation-scroll-output t))
|
||||
|
||||
|
@ -654,6 +661,14 @@ MODE1 is enabled and vice-versa."
|
|||
(oni:add-hooks 'text-mode-hook
|
||||
#'auto-fill-mode #'flyspell-mode 'oni:make-readable)
|
||||
|
||||
;; Turn off FCI when company completion starts and turn it on again
|
||||
;; when it finishes or is cancelled. This is to work around a
|
||||
;; long-standing incompatibility between company (as well as
|
||||
;; auto-complete) and fill-column-indicator.
|
||||
(add-hook 'company-completion-started-hook (lambda (&rest _) (fci-mode -1)))
|
||||
(add-hook 'company-completion-cancelled-hook (lambda (&rest _) (fci-mode 1)))
|
||||
(add-hook 'company-completion-finished-hook (lambda (&rest _) (fci-mode 1)))
|
||||
|
||||
;; Load my theme
|
||||
(if (daemonp)
|
||||
(add-hook 'after-make-frame-functions 'oni:set-theme-graphically)
|
||||
|
@ -753,7 +768,8 @@ MODE1 is enabled and vice-versa."
|
|||
(desktop-registry-auto-register)
|
||||
(yas-global-mode)
|
||||
(projectile-global-mode)
|
||||
(hes-mode))
|
||||
(hes-mode)
|
||||
(global-company-mode))
|
||||
|
||||
(with-eval-after-load 'ruby
|
||||
(global-rinari-mode))
|
||||
|
|
Loading…
Reference in a new issue