Mosè Giordano <[email protected]> writes:

>> Looks good to me.  But there's one thing I'm not sure.  Styles like
>> amsmath.el add environments to `LaTeX-label-alist', so what should a
>> user do, e.g., to tell auctex that she doen't want labels for align
>> environments?
>
> Indeed I'm not convinced that style files should change the value of
> customizable variables.
>
>> AFAICS, she would need to create an own amsmath.el style file in
>> `TeX-style-private' which removes the "align" entry from
>> `LaTeX-label-alist'.  Could you please check if that works, and if so,
>> document it.  (Or if there is a better way, that's also fine).
>
> In the patch I submitted, the amsmath and longtable environments are
> appended to `LaTeX-label-alist', instead of being prepended as they
> were before, so a user can add a
>     ("align" . nil)
> entry in `LaTeX-label-alist' and it won't be overridden by amsmath.el.

Ah, I see.  That's a good solution in my book.

> Actually, I believe the best way would be to add amsmath and longtable
> environments to default `LaTeX-label-alist' in latex.el.

No, I think it's reasonable that the styles do that on their own.  Else,
we'd need to add each and every environment that may be labeled in
latex.el which kind of defeats the purpose of styles.  I.e., when
someone wrote a style for the foobar package, he would need to know that
he can add to all auctex variables except for `LaTeX-label-alist' which
he should modify directly in latex.el.  That doesn't make sense.

Bye,
Tassilo

_______________________________________________
auctex-devel mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/auctex-devel

Reply via email to