Re: Problem with title fontification

Ralf Angeli <[email protected]> Thu, 17 Mar 2005 13:40:38 +0100
Newsgroups gmane.emacs.auc-tex
Message-ID <[email protected]>
* Franz Haeuslschmid (2005-03-17) writes:

> I found that setting the variable `font-latex-title-fontify' to `color' does
> have no effect for me. I have to manipulate the four title faces separately
> instead.
>
>
> Emacs  : XEmacs 21.4 (patch 10) "Military Intelligence" [Lucid] (sparc-sun-solaris2.9) of Wed Dec 11 2002 on r2d2

This looks like an incompatibility with XEmacs.

Technically it works like this: For a face in font-latex there exists
both a face definition (instantiated with `defface') and a variable
the same name (instantiated with `defvar').  I haven't looked at the
code, but if I understand the comment

;; We now allow a FACENAME in `font-lock-keywords' to be any expression that
;; returns a face.

in font-lock.el correctly, the font lock code can evaluate the
separately defined variable in order to refer to the face definition.
font-latex takes advantage of this by letting the variable point to a
different face in case the 'color option is used in
`font-latex-title-fontify'.

It seems that this mechanism is not working in XEmacs.  Probably
XEmacs' internals do not work with separate variables.  The comment I
found at the same place in XEmacs' font-lock.el like the one quoted
above seems to indicate this:

;; #### barf gag retch.  Horrid FSF lossage that we need to
;; keep around for compatibility with font-lock-keywords that
;; forget to properly quote their faces.

IIRC it was mentioned on the emacs-devel list as well that separate
variables for faces should be deprecated, but I don't know what
happened to this proposal.

This whole thing isn't really documented anyway, so what I wrote above
is how I interpret the situation without actually looking closer at
the code.


Long story short, switching between 'color and 'height in XEmacs
requires a different implementation than the one we currently have.  I
don't know if I will find time for this, though.

> Package: AUCTeX CVS-1.13 (2005-02-11)

The XEmacs package still does net set the correct version number?

-- 
Ralf