欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

emacs & auto-complete 博客分类: 编辑器 emacsauto-complete

程序员文章站 2024-03-21 10:34:46
...

下载最新版本 http://cx4a.org/software/auto-complete/#Latest_Stable
解压到 ~/.emacs.d/plugins/auto-complete-1.3.1
然后更改.emacs
下载auto math
git clone https://github.com/vitoshka/ac-math.git

;;auto-complete
(add-to-list 'load-path "~/.emacs.d/plugins/auto-complete-1.3.1")
(require 'auto-complete-config)
(add-to-list 'ac-dictionary-directories "~/.emacs.d/plugins/auto-complete-1.3.1/dict")
(ac-config-default)

(require 'ac-math)
(add-to-list 'ac-modes 'latex-mode) ; make auto-complete aware of {{{latex-mode}}}
(defun ac-latex-mode-setup () ; add ac-sources to default ac-sources
(setq ac-sources
(append '(ac-source-math-unicode ac-source-math-latex ac-source-latex-commands)
ac-sources))
)
(add-hook 'LaTeX-mode-hook 'ac-latex-mode-setup)
相关标签: emacs auto-complete