Re: vertical-align (5.4.4)

>> <P>This is an inline equation:
>>   <IMG STYLE="height: 120px; width: 300px; vertical-align: -45px"
>>        SRC="equation.gif">
>> </P>
>
>Yes, this is much cleaner.
>
>Replaced elements have no baseline by default. Can they be given one?
>
>  <P>This is an inline equation:
>    <IMG STYLE="font-size: 100%;
>                height: 4em; width: 10em;
>                vertical-align: -5%"
>         SRC="equation.gif">
>  </P>
>
>If so, the above would produce a graphic that is both sized and
>vertically-aligned relative to the parent's font.

Now that IS good!  As to the baseline, if there was a way to define one I
wouldn't need to be asking these questions!  I think the assumption I saw
everywhere in the CSS spec was that replaced items have a baseline value
equal to the bottom of the object.

You're assuming here that a replaced item can actually have a font-size.  Is
that true? It can't have a line-height currently.  If it could have a line
height, then I'd modify your example to be:

  <P>This is an inline equation:
    <IMG STYLE="font-size: 100%;
                line-height=100%;
                height: 4em; width: 10em;
                vertical-align: -5%"
         SRC="equation.gif">
  </P>

because the vertical-align percentage is based on the line-height, so we
need to define it. I guess I could surround the image with a <SPAN> as I did
at the top, but it would be nice if the thing were clean and self-contained. 

I still think we need the ability to specifiy other types of units in
vertical-align. In this particular case, I'd want to define it in terms of
'em', since that is how the height was defined.  If the % related to the
font-size or the object height David's example would be perfect, but it
doesn't right now.

Does anyone have a feeling as to why other units are NOT allowed in
vertical-align?
Jim King
Product Manager
jimk@mathtype.com

==================================================================
Design Science, Inc.            Sales:   sales@mathtype.com
4028 Broadway                   Support: support@mathtype.com
Long Beach, CA 90803            
USA                             World Wide Web: 
voice: 310-433-0685                 http://www.mathtype.com
fax: 310-433-6969
==================================================================

Received on Monday, 16 December 1996 13:30:48 UTC