On Wed, 14 May 2008 15:48:01 +0200
"Heidemeier Dr, Joachim" <[EMAIL PROTECTED]> wrote:

> Triggered by a recent question in lyx-users I fiddled a little bit with the 
> usage of the BPChem style from lyx. As BPChem is a single latex command I 
> tried the definition of a Char Style:
> 
> CharStyle ChemFormula
>         LatexType             Command
>         LatexName             BPChem
>         LabelFont
>           Family              Roman
>           Color               blue
>         EndFont
>         Preamble
>                \usepackage{BPChem}
>         EndPreamble
> End
> 
> I ran into the following problem:
> 
> the argument to the \BPChem command might contain special characters (tex 
> control words) like \_ or \^ for sub- or superscripts. When Lyx generates 
> latex those backslashes will be escaped so that they became characters to be 
> typesetted. Is there another possibility besides ERT to prevent those 
> backslashes from beeing escaped during Latex generation?
> 
> Thanks
> 
> --
> Dr. Joachim Heidemeier
> c/o Umweltbundesamt FG II 2.2
> Tel.: +49340 2103-2780
> eMail: [EMAIL PROTECTED]


Have a look at stdinsets.inc in the layouts directory. I think what you need is 
the PassThru keyword.

- Martin

Reply via email to