Erich Subscriptions <
address@hidden> writes:
Hi Erich,
I see surprising effects when using AucTeX 11.87 on OSX 10.9 with
Emacs 24.3
With the following code segment
\newtheorem{thm}{Theorem}
\theoremstyle{definition}
\newtheorem{defn}{Definition}
"\newtheorem" is colored purple, but "\theoremstyle" is colored grey.
That's because AUCTeX knows that \newtheorem is a valid macro whereas it
sees that you \theoremstyle as a macro, but it doesn't know it.
When AUCTeX sees a \usepackage{foobar}, it'll try to run a foobar.el
style file, and that has the chance to make AUCTeX aware of additional
macros and environments defined by that package which will also change
the fontification. That \theoremstyle is just grey means that either
there is no style file for the package declaring it, or that style file
just doesn't add \theoremstyle as a valid macro.