0

I use additional Emacs modes in conjunction with AUCTeX, such as writegood-mode and rainbow-delimiters-mode, which each add their custom highlights to the current buffer. Unfortunately, after refreshing AUCTeX style hooks (C-n), the highlights are gone and I have to manually disable and re-enable the other modes. Is there an effective way to do this automatically each time after C-n? I was not able to find a hook that is executed after the style hook refresh.

  • Have you tried TeX-update-style-hook hook? – giordano Oct 11 '15 at 16:19
  • Thank you, that did the trick! I must have overlooked this hook. – b4t3m4n Oct 11 '15 at 18:23
1

The hook you're looking for is TeX-update-style-hook. Its documentation (C-h v TeX-update-style-hook RET) reads

Hook run as soon as style specific hooks were applied.

To be precise, it's run at the end of the function TeX-update-style, which is called when (re-)opening a new TeX buffer or when TeX-normal-mode is executed.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.