auctex
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [AUCTeX] Sophisticated macro highlighting and biblatex support


From: Ralf Angeli
Subject: Re: [AUCTeX] Sophisticated macro highlighting and biblatex support
Date: Thu, 08 Oct 2009 18:51:50 +0200

* Frederik (2009-10-06) writes:

> I'm trying to get my macros highlighted.
> I managed to color the "\footcite" command of biblatex the correct way. 
> What I did: M-x customize-group RET font-latex-keywords RET, then I 
> chose "Font Latex Match Reference Keywords" and added "footcite".
>
> But I've problems to do this with "\footcites", as it provides 
> sophisticated ways to enter bibliographic references.
> e.g. "\footcites[20]{author1}[some remarks on this, cf.][33]{author2}"
> Now just the part up to and including "{author1}" gets highlighted.
>
> User-defiened keyword classes don't provide a way to highlight 
> references like this, do they? Because I only found the possibility to 
> work with entries like "\command[...]{...}", "{\foo text}" and "\foo".
>
> Any hints?

If your AUCTeX version is recent enough you can specify the arguments to
fontify.

> Furthermore I wanted to know if biblatex gets integrated into RefTeX.

I doubt that biblatex will get integrated, but perhaps support for it.
This will happen faster if people interested in the functionality
contribute patches.

> I've put this into my .emacs:
> ---8<----------------------------------------------
> (setq reftex-cite-format
>        '((?\C-m . "\\cite[]{%l}")
>       (?f . "\\footcite[][]{%l}")
>          (?t . "\\textcite[]{%l}")
>          (?p . "\\parencite[]{%l}")
>          (?o . "\\citepr[]{%l}")
>          (?n . "\\nocite{%l}")))
> (setq reftex-cite-prompt-optional-args t)
> ---8<----------------------------------------------
>
> At least this makes it possible to work with "\footcite", but I don't 
> know how to implement "\footcites"...

You mean how to get prompted multiple times for the BibTeX label?  I
don't think this is possible at the moment.  One would probably have to
extend the implementation to handle mandatory arguments similar to
optional ones.

> Also it would be great if AucTeX recognized that biblatex is used in 
> order to have an automatic BibTeX run on doing C-c -- but this is not 
> that important.

Somebody would have to extend the respective sentinel function to
recognize the biblatex output.

-- 
Ralf




reply via email to

[Prev in Thread] Current Thread [Next in Thread]