Ralf Angeli a écrit :
> You should not use it in a hook at all.  Just use the code I proposed
> and be done.
>
>   
Dear Ralf,

Sorry to dwell on it :

I was using it in a hook in the first place because I needed that the 
variable LaTeX-font-list be defined, which you overcome by the using the 
eval-after-load function in the code that you proposed.

What you propose is working perfect for what I need, but I thought that 
a mode hook was the preferred placeholder to make mode specific 
customizations, when you need to modify some default setting that maybe 
initialized at the mode outset. Using a hook that is called when the 
mode is entered has the advantage that the setting is made every time 
that the mode is entered (for each LaTeX file I open), whereas making 
the setting on the module loading will make the setting only once in an 
Emacs session.

In the case of LaTeX-font-list, it does not make a difference, because 
anyhow the variable is made buffer local and I want to customize it once 
and for all.  But if for instance I wanted to read some information from 
the minibuffer to select one in several possible LaTeX-font-list 
customizations, then your code would not make it, and a mode hook would 
be needed.

This is the reason why I was surprised that the LaTeX-mode-hook is too 
late when modifying the LaTeX-font-list, and this is why I am still 
thinking that there is some naming problem : it does not seem 
appropriate to name this variable LaTeX-font-list while there seems to 
be some AucTeX code reading it *before* LaTeX mode is entered. Shouldn't 
it be named TeX-latex-font-list, with LaTeX-font-list being an alias for 
backward compatibility ?

BR,
   Vincent.




_________________________________________________________________
Votre contact a choisi Hotmail, l'e-mail ultra sécurisé. Créez un compte 
gratuitement !
http://www.windowslive.fr/hotmail/default.asp
_______________________________________________
auctex mailing list
auctex@gnu.org
http://lists.gnu.org/mailman/listinfo/auctex

Reply via email to