Re: Protecting Math Environments

2001-08-01 Thread Tuukka Toivonen

On 1 Aug 2001, Jean-Marc Lasgouttes wrote:

  Rainer == Rainer Dorsch [EMAIL PROTECTED] writes:
 Rainer I am wondering, if it is possible to protect math
 Rainer environments. This is useful, if commands like
 Rainer \addcontentsline with non-robust commands are used.

It works if you enter math manually between pair of $'s.




Re: Protecting Math Environments

2001-08-01 Thread Tuukka Toivonen

On 1 Aug 2001, Jean-Marc Lasgouttes wrote:

  Rainer == Rainer Dorsch [EMAIL PROTECTED] writes:
 Rainer I am wondering, if it is possible to protect math
 Rainer environments. This is useful, if commands like
 Rainer \addcontentsline with non-robust commands are used.

It works if you enter math manually between pair of $'s.




Re: Protecting Math Environments

2001-08-01 Thread Tuukka Toivonen

On 1 Aug 2001, Jean-Marc Lasgouttes wrote:

> > "Rainer" == Rainer Dorsch <[EMAIL PROTECTED]> writes:
> Rainer> I am wondering, if it is possible to protect math
> Rainer> environments. This is useful, if commands like
> Rainer> \addcontentsline with non-robust commands are used.

It works if you enter math manually between pair of $'s.




Re: Protecting Math Environments

2001-06-21 Thread Rainer Dorsch

 Rainer Dorsch wrote:
  
   \newcommmand{\myMathEnv}{
 \begin{anyMathEnv}
 . all the mathstuff 
 \end{anyMathEnv}%
 
  I want to use the formula editor of lyx to enter the formulas. And it inserts
  in the latex file
  
  \( stuff \)
  
  but I need
  
  \protect\( stuff \protect\)
 
 i don't understand the sense of the second \protect.
 this works with the blue box, too

It simply does not work without the second protect :-)

 
 \newcommmand{\myMathEnv}{
 .. the lyx blue mathbox
 }

ok, something like \protect\myMathEnv{the lyx blue mathbox} might work.

I will experiment a little bit with it.

Thanks.

Rainer.










Re: Protecting Math Environments

2001-06-21 Thread Dekel Tsur

On Wed, Jun 20, 2001 at 08:23:07PM +0200, Rainer Dorsch wrote:
 I want to use the formula editor of lyx to enter the formulas. And it inserts 
 in the latex file
 
 \( stuff \)
 
 but I need
 
 \protect\( stuff \protect\)

Just put \protect in latex mode before the math inset, and also go into the
math inset, and put \protect at the end of the inset (for the second protect,
you will not see the backslash on screen).



Re: Protecting Math Environments

2001-06-21 Thread Rainer Dorsch

 Rainer Dorsch wrote:
  
   \newcommmand{\myMathEnv}{
 \begin{anyMathEnv}
 . all the mathstuff 
 \end{anyMathEnv}%
 
  I want to use the formula editor of lyx to enter the formulas. And it inserts
  in the latex file
  
  \( stuff \)
  
  but I need
  
  \protect\( stuff \protect\)
 
 i don't understand the sense of the second \protect.
 this works with the blue box, too

It simply does not work without the second protect :-)

 
 \newcommmand{\myMathEnv}{
 .. the lyx blue mathbox
 }

ok, something like \protect\myMathEnv{the lyx blue mathbox} might work.

I will experiment a little bit with it.

Thanks.

Rainer.










Re: Protecting Math Environments

2001-06-21 Thread Dekel Tsur

On Wed, Jun 20, 2001 at 08:23:07PM +0200, Rainer Dorsch wrote:
 I want to use the formula editor of lyx to enter the formulas. And it inserts 
 in the latex file
 
 \( stuff \)
 
 but I need
 
 \protect\( stuff \protect\)

Just put \protect in latex mode before the math inset, and also go into the
math inset, and put \protect at the end of the inset (for the second protect,
you will not see the backslash on screen).



Re: Protecting Math Environments

2001-06-21 Thread Rainer Dorsch

> Rainer Dorsch wrote:
> > 
> > > \newcommmand{\myMathEnv}{
> > >   \begin{anyMathEnv}
> > >   . all the mathstuff 
> > >   \end{anyMathEnv}%
> 
> > I want to use the formula editor of lyx to enter the formulas. And it inserts
> > in the latex file
> > 
> > \( stuff \)
> > 
> > but I need
> > 
> > \protect\( stuff \protect\)
> 
> i don't understand the sense of the second \protect.
> this works with the blue box, too

It simply does not work without the second protect :-)

> 
> \newcommmand{\myMathEnv}{
> .. the lyx blue mathbox
> }

ok, something like \protect\myMathEnv{the lyx blue mathbox} might work.

I will experiment a little bit with it.

Thanks.

Rainer.










Re: Protecting Math Environments

2001-06-21 Thread Dekel Tsur

On Wed, Jun 20, 2001 at 08:23:07PM +0200, Rainer Dorsch wrote:
> I want to use the formula editor of lyx to enter the formulas. And it inserts 
> in the latex file
> 
> \( stuff \)
> 
> but I need
> 
> \protect\( stuff \protect\)

Just put \protect in latex mode before the math inset, and also go into the
math inset, and put \protect at the end of the inset (for the second protect,
you will not see the backslash on screen).



Protecting Math Environments

2001-06-20 Thread Rainer Dorsch


Hello,

I am wondering, if it is possible to protect math environments. This is 
useful, if commands like \addcontentsline with non-robust commands are used.

Thank you.

Rainer.




Re: Protecting Math Environments

2001-06-20 Thread Herbert Voss

Rainer Dorsch wrote:
 
 I am wondering, if it is possible to protect math environments. This is
 useful, if commands like \addcontentsline with non-robust commands are used.

i don't know, if i understand your problem well.


\newcommmand{\myMathEnv}{
  \begin{anyMathEnv}
  . all the mathstuff 
  \end{anyMathEnv}%
}

in text

\addcontentsline{toc}{chapter}{\protect\myMathEnv}

Herbert

-- 
http://www.educat.hu-berlin.de/~voss/lyx/



Re: Protecting Math Environments

2001-06-20 Thread Herbert Voss

Rainer Dorsch wrote:
 
  \newcommmand{\myMathEnv}{
\begin{anyMathEnv}
. all the mathstuff 
\end{anyMathEnv}%

 I want to use the formula editor of lyx to enter the formulas. And it inserts
 in the latex file
 
 \( stuff \)
 
 but I need
 
 \protect\( stuff \protect\)

i don't understand the sense of the second \protect.
this works with the blue box, too

\newcommmand{\myMathEnv}{
.. the lyx blue mathbox
}

Herbert

-- 
http://www.educat.hu-berlin.de/~voss/lyx/




Protecting Math Environments

2001-06-20 Thread Rainer Dorsch


Hello,

I am wondering, if it is possible to protect math environments. This is 
useful, if commands like \addcontentsline with non-robust commands are used.

Thank you.

Rainer.




Re: Protecting Math Environments

2001-06-20 Thread Herbert Voss

Rainer Dorsch wrote:
 
 I am wondering, if it is possible to protect math environments. This is
 useful, if commands like \addcontentsline with non-robust commands are used.

i don't know, if i understand your problem well.


\newcommmand{\myMathEnv}{
  \begin{anyMathEnv}
  . all the mathstuff 
  \end{anyMathEnv}%
}

in text

\addcontentsline{toc}{chapter}{\protect\myMathEnv}

Herbert

-- 
http://www.educat.hu-berlin.de/~voss/lyx/



Re: Protecting Math Environments

2001-06-20 Thread Herbert Voss

Rainer Dorsch wrote:
 
  \newcommmand{\myMathEnv}{
\begin{anyMathEnv}
. all the mathstuff 
\end{anyMathEnv}%

 I want to use the formula editor of lyx to enter the formulas. And it inserts
 in the latex file
 
 \( stuff \)
 
 but I need
 
 \protect\( stuff \protect\)

i don't understand the sense of the second \protect.
this works with the blue box, too

\newcommmand{\myMathEnv}{
.. the lyx blue mathbox
}

Herbert

-- 
http://www.educat.hu-berlin.de/~voss/lyx/




Protecting Math Environments

2001-06-20 Thread Rainer Dorsch


Hello,

I am wondering, if it is possible to protect math environments. This is 
useful, if commands like \addcontentsline with non-robust commands are used.

Thank you.

Rainer.




Re: Protecting Math Environments

2001-06-20 Thread Herbert Voss

Rainer Dorsch wrote:
> 
> I am wondering, if it is possible to protect math environments. This is
> useful, if commands like \addcontentsline with non-robust commands are used.

i don't know, if i understand your problem well.


\newcommmand{\myMathEnv}{
  \begin{anyMathEnv}
  . all the mathstuff 
  \end{anyMathEnv}%
}

in text

\addcontentsline{toc}{chapter}{\protect\myMathEnv}

Herbert

-- 
http://www.educat.hu-berlin.de/~voss/lyx/



Re: Protecting Math Environments

2001-06-20 Thread Herbert Voss

Rainer Dorsch wrote:
> 
> > \newcommmand{\myMathEnv}{
> >   \begin{anyMathEnv}
> >   . all the mathstuff 
> >   \end{anyMathEnv}%

> I want to use the formula editor of lyx to enter the formulas. And it inserts
> in the latex file
> 
> \( stuff \)
> 
> but I need
> 
> \protect\( stuff \protect\)

i don't understand the sense of the second \protect.
this works with the blue box, too

\newcommmand{\myMathEnv}{
.. the lyx blue mathbox
}

Herbert

-- 
http://www.educat.hu-berlin.de/~voss/lyx/