auctex
[Top][All Lists]
Advanced

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

Re: [AUCTeX] font specifier with an argument/textcolor?


From: Ralf Angeli
Subject: Re: [AUCTeX] font specifier with an argument/textcolor?
Date: Tue, 29 Dec 2009 21:27:44 +0100

* Peter Horst (2009-12-28) writes:

> Is it possible to customize a font specifier that would facilitate the 
> insertion of either:
>
> \textcolor{Red}{*}
>
> or
>
> \textcolor{$COLOR}{*} where $COLOR is an argument to be entered by the user?
>
> I tried entering '{\color{Red}' and '}' into the TeX-font-list in the 
> AUCTeX customization buffer, under the ^A rubric that AUCTeX offered 
> when I hit "INS", but it didn't work (i.e. if I hit CRTL-C CTRL-F CTRL-A 
> after saving that option, nothing happens).  Do I maybe need to escape 
> the brackets in {Red} somehow? 

Are you trying to use this with a LaTeX file?  Then you'd have to
customize `LaTeX-font-list'.  Note however, in `LaTeX-font-list' `C-a'
is already taken by \mathcal.

And the font insertion mechanism only allows you to specify the strings
before and after the text you selected in the buffer.  Prompting for an
additional parameter is not supported.  In order to get that you can
write an AUCTeX style file for the package defining the macro (probably
color.sty or xcolor.sty).  See (info "(auctex)Style Files") for further
information.

-- 
Ralf




reply via email to

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