.emacs.d/init.d/text/latex.el
tastytea 2d576fec10 Rename .emacs/init → .emacs/init.d and fix comment-face.
Inheriting `font-lock-comment-face` in `font-lock-comment-face` would lock up
Emacs.
2019-12-26 19:23:43 +01:00

39 lines
854 B
EmacsLisp

;;; latex.el --- Settings for LaTeX. -*- lexical-binding: t; -*-
;; Time-stamp: <2019-12-26T07:41:35+00:00>
;;; Commentary:
;;; Code:
(use-package tex-site
:ensure auctex
:if (executable-find "xetex")
:functions (TeX-revert-document-buffer)
:custom
(TeX-parse-self t) ; Enable parse on load.
(TeX-auto-save t) ; Enable parse on save
(TeX-PDF-mode t) ; PDF mode (rather than DVI-mode)
(TeX-engine 'xetex)
:mode
("\\.tex$" . LaTeX-mode)
:config
;; To have the buffer refresh after compilation.
(add-hook 'TeX-after-compilation-finished-functions
#'TeX-revert-document-buffer)
)
;; Auto complete for LaTeX.
(use-package company-auctex
:after (auctex)
:hook
(LaTeX-mode . company-auctex-init)
)
(provide 'text/latex)
;;; latex.el ends here