Re: Numbering a figure as an equation

2001-05-11 Thread Dekel Tsur

On Wed, May 09, 2001 at 09:07:21PM +0200, Herbert Voss wrote:
> just before you insert the image, means between first \hfill
> and image in tex(red)
> 
> \parbox{the width}{
> 
> and just behind the image the closing parenthesis
> }
> 
> for "the width" have a look at the boundig box values
> in your eps-file. maybe the fifth line in the file.
> choose the x-value and insert it as width, for example
> \parbox{300pt}{

Why not let latex compute the space ?
Here is an alternative way to do what you want:
1. Put the following in latex mode:
\begin{equation}\begin{array}{c}\mbox{

2. Insert figure (as inline) 

3. Put the following (in latex mode)
}\end{array}

4. Insert label

5. Put the following (in latex mode)
\end{equation}



Re: Numbering a figure as an equation

2001-05-10 Thread Herbert Voss

Kevin Gross wrote:
> 
> Excellent!  This will work just fine.  However, it would be even better if
> the equation number was vertically centered with the figure.  (My picture is
> a bit tall.)  For example, I would prefer this
> 
> [ ]
> [   An eps figure of a reaction   ]   (2)
> [ ]
> 
> to what I get with your method, namely
> 
> [ ]
> [   An eps figure of a reaction   ]
> [ ]   (2)

just before you insert the image, means between first \hfill
and image in tex(red)

\parbox{the width}{

and just behind the image the closing parenthesis
}

for "the width" have a look at the boundig box values
in your eps-file. maybe the fifth line in the file.
choose the x-value and insert it as width, for example
\parbox{300pt}{

you can also play araound with a width in cm.

a parbox is centered by default if there are no
other options vor vertical alignment, therefore 
it should work

Herbert

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



Re: Numbering a figure as an equation

2001-05-10 Thread Kevin Gross

Excellent!  This will work just fine.  However, it would be even better if 
the equation number was vertically centered with the figure.  (My picture is 
a bit tall.)  For example, I would prefer this

[ ]
[   An eps figure of a reaction   ]   (2)
[ ]

to what I get with your method, namely

[ ]
[   An eps figure of a reaction   ]
[ ]   (2)

Also note that I manually placed ()'s around the number.

Thanks so much for your help!

Kevin


On Wednesday 09 May 2001 13:53, you wrote:
> the following all in _one_ line!
>
> hit ctrl-space
> insert->special characters->hfill
> insert-image (or click on button) as usual. not as float!
> insert->special characters->hfill
> write in tex (red): \refstepcounter{equation}
> insert->label->any label you like
> write in tex (red): (\theequation)
>
> now you can do refs via lyx as usual
>
> Herbert



Re: Numbering a figure as an equation

2001-05-10 Thread Herbert Voss

Kevin Gross wrote:
> 
> Hi,
> 
> I have a picture (eps format) of a chemical reaction that I would like to
> enter in the text as if it were a labeled equation.  I  want the chemical
> reaction labeled in sequence with the other equations, most of which are
> actual math.  Here is an example of what I would like to do:
> 
>Blah blah blah, words words words...
>   1+1=2 (1)
>Blah blah blah in Equation 1.  Blah blah
>   [An eps picture of some reaction] (2)

the following all in _one_ line!

hit ctrl-space
insert->special characters->hfill
insert-image (or click on button) as usual. not as float!
insert->special characters->hfill
write in tex (red): \refstepcounter{equation}
insert->label->any label you like
write in tex (red): (\theequation)

now you can do refs via lyx as usual

Herbert

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



Numbering a figure as an equation

2001-05-10 Thread Kevin Gross

Hi,

I have a picture (eps format) of a chemical reaction that I would like to 
enter in the text as if it were a labeled equation.  I  want the chemical 
reaction labeled in sequence with the other equations, most of which are 
actual math.  Here is an example of what I would like to do:

   Blah blah blah, words words words...
  1+1=2 (1)
   Blah blah blah in Equation 1.  Blah blah
  [An eps picture of some reaction] (2)
   For the reaction shown in Equation 2 above...

I hope I've been clear on what I am trying to accomplish.  Thanks for your 
help.

Kevin Gross