Refactor company integration

This commit is contained in:
Henrik Lissner 2015-10-14 03:39:32 -04:00
parent c7f2f10b18
commit d073d61531
14 changed files with 45 additions and 27 deletions

View file

@ -14,5 +14,18 @@
(company-complete)
(call-interactively 'company-select-previous))))
;;;###autoload
(defun narf/company-complete-common-or-complete-full ()
(interactive)
(when (company-manual-begin)
(if (eq last-command #'company-complete-common-or-cycle)
(let ((company-selection-wrap-around t))
(call-interactively #'company-complete-selection))
(let ((buffer-mod-tick (buffer-chars-modified-tick)))
(call-interactively #'company-complete-common)
(when (= buffer-mod-tick (buffer-chars-modified-tick))
(call-interactively #'company-complete-selection)
(call-interactively #'company-complete))))))
(provide 'defuns-company)
;;; defuns-company.el ends here