Skip to content

Instantly share code, notes, and snippets.

@ixxra
Created June 13, 2018 00:17
Show Gist options
  • Save ixxra/b39c1219dc908d6bc18ef9b13792bc13 to your computer and use it in GitHub Desktop.
Save ixxra/b39c1219dc908d6bc18ef9b13792bc13 to your computer and use it in GitHub Desktop.
How to highlight a custom command in emacs with auctex
;; Reference: https://www.flannaghan.com/2013/01/09/command-highlight
;;This option will hightlight the content inside the parens
(setq font-latex-user-keyword-classes
'(("my-warning-commands"
(("fixme" "{"))
(:background "red" :foreground "black")
command)))
;; This option will hightlight the command itself
(setq font-latex-match-warning-keywords
'(("fixme" "{") ))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment