From 9e8d6263625450203356e0d20e372179563746a4 Mon Sep 17 00:00:00 2001 From: Lucas Sta Maria Date: Wed, 28 Feb 2024 19:01:06 -0500 Subject: [PATCH] fix(emacs): add company completion for latex Signed-off-by: Lucas Sta Maria --- .emacs.d/include/latexconfig.el | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.emacs.d/include/latexconfig.el b/.emacs.d/include/latexconfig.el index 62c9539..675036f 100644 --- a/.emacs.d/include/latexconfig.el +++ b/.emacs.d/include/latexconfig.el @@ -7,6 +7,9 @@ (require 'cdlatex) (require 'f) +(require 'company) +(require 'company-math) + (defun custom-compile-latex () "Run the `just' command -- the command I use to compile my environment." (interactive) @@ -109,6 +112,10 @@ (set (make-local-variable 'LaTeX-electric-left-right-brace) t) (set 'preview-scale-function 0.75) + (setq-local company-backends + (append '((company-math-symbols-latex company-latex-commands)) + company-backends)) + (LaTeX-add-environments '("theorem" latex-env-theorem) '("corollary" latex-env-theorem)