[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Mode hooks for latex and tex files
From: |
Arash Esbati |
Subject: |
Re: Mode hooks for latex and tex files |
Date: |
Mon, 02 Dec 2024 21:38:33 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
Heime <heimeborgia@protonmail.com> writes:
> On Tuesday, December 3rd, 2024 at 8:17 AM, Arash Esbati <arash@gnu.org> wrote:
>
>> The mode names above (and the corresponding hooks) are all defined in
>> tex-mode.el which is distributed with Emacs; they don't belong to
>> AUCTeX:
>>
>> $ grep define-derived-mode tex-mode.el
>> (define-derived-mode tex-mode text-mode "generic-TeX"
>> (define-derived-mode plain-tex-mode tex-mode "TeX"
>> (define-derived-mode latex-mode tex-mode "LaTeX"
>> (define-derived-mode slitex-mode latex-mode "SliTeX"
>> (define-derived-mode tex-shell shell-mode "TeX-Shell"
>> (define-derived-mode doctex-mode latex-mode "DocTeX"
>>
>> As you can see, tex-mode.el breaks every "rule" you think you're
>> describing with "typical package-prefixed predicate style". A "mylib-"
>> prefix might be a natural choice for single file libraries, but it isn't
>> a must as long you get the prefix right.
>
> Correct, it breaks every rule. Instead of a prefix, the AUCTeX developers
> decided upon a camel-case variant. Their package does not fit nicely with
> emacs development preferred way.
I don't how often I have to repeat this: tex-mode.el is part of Emacs
and not part of AUCTeX:
http://git.savannah.gnu.org/cgit/emacs.git/tree/lisp/textmodes/tex-mode.el
And AFAICT, it does the job right.
Best, Arash