all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* latex fontification
@ 2014-06-30 21:51 François Patte
  2014-07-01  9:02 ` latex fontification [more] François Patte
  0 siblings, 1 reply; 3+ messages in thread
From: François Patte @ 2014-06-30 21:51 UTC (permalink / raw)
  To: help-gnu-emacs

Bonjour,

I would like to have a syntax colorisation for some TeX commands using
Auctex.

I found on the Internet this way: add to .emacs file:

(setq font-latex-match-reference-keywords
  '(
    ("footnotea" "[{")
    ("footnoteb" "[{")
    ("footnotec" "[{")
    ("edtext"    "[{")
    ("Afootnote" "[{")
    ("Bfootnote" "[{")
    ("Cfootnote" "[{")
    ("lemma"     "[{")))

And the commands \footnotes, \footnoteb etc will be highlighted...

This doesn't work for me.... Did I miss something?

Thank you
-- 
François Patte
Université Paris Descartes


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: latex fontification [more]
  2014-06-30 21:51 latex fontification François Patte
@ 2014-07-01  9:02 ` François Patte
  2014-07-03 22:19   ` Michael Heerdegen
  0 siblings, 1 reply; 3+ messages in thread
From: François Patte @ 2014-07-01  9:02 UTC (permalink / raw)
  To: help-gnu-emacs

Le 30/06/2014 23:51, François Patte a écrit :
> Bonjour,
> 
> I would like to have a syntax colorisation for some TeX commands using
> Auctex.
> 
> I found on the Internet this way: add to .emacs file:
> 
> (setq font-latex-match-reference-keywords
>   '(
>     ("footnotea" "[{")
>     ("footnoteb" "[{")
>     ("footnotec" "[{")
>     ("edtext"    "[{")
>     ("Afootnote" "[{")
>     ("Bfootnote" "[{")
>     ("Cfootnote" "[{")
>     ("lemma"     "[{")))
> 
> And the commands \footnotes, \footnoteb etc will be highlighted...
> 
> This doesn't work for me.... Did I miss something?

I have to add this: it works for some buffer and not for some other!

I tried to force latex mode: M-x latex-mode but this does not work

symbol's function definition is void : make-local-hook

When I load a file with .tex extension, I have a similar message en the
buffer "messages":

File mode specification error: (void-function make-local-hook)

But for some file I have this in the lower bar:

(Latex/P Bcite Arev Fill)

And in some other:

(Fundamental Bcite Arev Fill)

Why?


Moreover, I found on the web that make-local-hook is now deprecated and
has disappeared from Emacs 24, but I am running Emacs 24.3.1

Can someone help me?

thank you



-- 
François Patte
Université Paris Descartes


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: latex fontification [more]
  2014-07-01  9:02 ` latex fontification [more] François Patte
@ 2014-07-03 22:19   ` Michael Heerdegen
  0 siblings, 0 replies; 3+ messages in thread
From: Michael Heerdegen @ 2014-07-03 22:19 UTC (permalink / raw)
  To: help-gnu-emacs

> > Bonjour,

Hi!

I have no experience with this, I just had a quick look at the code.

> > I would like to have a syntax colorisation for some TeX commands using
> > Auctex.
> > 
> > I found on the Internet this way: add to .emacs file:
> > 
> > (setq font-latex-match-reference-keywords
> >   '(
> >     ("footnotea" "[{")
> >     ("footnoteb" "[{")
> >     ("footnotec" "[{")
> >     ("edtext"    "[{")
> >     ("Afootnote" "[{")
> >     ("Bfootnote" "[{")
> >     ("Cfootnote" "[{")
> >     ("lemma"     "[{")))
> > 
> > And the commands \footnotes, \footnoteb etc will be highlighted...
> > 
> > This doesn't work for me.... Did I miss something?
>
> I have to add this: it works for some buffer and not for some other!

I guess this is because the variable is buffer local.  Use
`setq-default` instead of `setq` to set the global binding.

> File mode specification error: (void-function make-local-hook)
>
> But for some file I have this in the lower bar:
>
> (Latex/P Bcite Arev Fill)
>
> And in some other:
>
> (Fundamental Bcite Arev Fill)
>
> Why?
>
>
> Moreover, I found on the web that make-local-hook is now deprecated and
> has disappeared from Emacs 24, but I am running Emacs 24.3.1

I think it's a bug - in `bib-cite-minor-mode`.  There was obviously
code added for xemacs (which still has `make-local-hook`), but it is
used unconditionally for all Emacsen - thus the error.

To prevent this, avoid turning on bib-cite-minor-mode.  Having
fundamental mode in one buffer (as you saw it) is probably a side effect
of this error.

BTW, please make a bug report if this problem hasn't been reported or
fixed yet.


HTH,

Michael.




^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-07-03 22:19 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-30 21:51 latex fontification François Patte
2014-07-01  9:02 ` latex fontification [more] François Patte
2014-07-03 22:19   ` Michael Heerdegen

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.