Henri Sivonen wrote:
> 
> <[EMAIL PROTECTED]> wrote:
...
> > There may be something in the specs to explain this 
> > behaviour, but  I haven't found it.
> 
> Links to the spec can be found at
> http://www.hut.fi/u/hsivonen/standards.html
...


Thanks, but I found the spec some time ago... ;-)

However, in your document you seem to refer only to inline non-replaced
elements containing inline replaced elements.


The point is, I don't see anything in the spec to explain the use of
'line-height' in the calculation of:

1. the height of an inline replaced element

   [Re 'height' - "This property specifies the content height of boxes
generated by block-level and replaced elements. This property does not
apply to non-replaced inline-level elements. The height of a
non-replaced inline element's boxes is given by the element's (possibly
inherited) 'line-height' value." -  10.5
   and - "If 'height' has a specified value of 'auto' and 'width' also
has a specified value of 'auto', the element's intrinsic height is the
computed value of 'height'." -  10.6.2]


2. the height of the inline box for an inline replaced element

   [Re 'line-height' - "If the property is set on an inline-level
element, it specifies the exact height of each box generated by the
element. (Except for inline replaced elements, where the height of the
box is given by the 'height' property.)"
    and - "Note that replaced elements have a 'font-size' and a
'line-height' property, even if they are not used directly to determine
the height of the box" -  10.8.1]


3. the height of a line box containing only the inline box for an inline
replaced element

   ["The line box height is the distance between the uppermost box top
and the lowermost box bottom." -  10.8]


4. the height of a table cell containing only an inline replaced element

   ["In CSS2, the height of a cell box is the maximum of the table
cell's 'height' property and the minimum height required by the content
(MIN). A value of 'auto' for 'height' implies a computed value of MIN."
-  17.5.3]


5. the height of a table row containing a table cell containing only an
inline replaced element.

   ["The height of a 'table-row' element's box is calculated once the
user agent has all the cells in the row available: it is the maximum of
the row's specified 'height' and the minimum height (MIN) required by
the cells. A 'height' value of 'auto' for a 'table-row' means the
computed row height is MIN. MIN depends on cell box heights and cell box
alignment (much like the calculation of a line box height). -  17.5.3]


6. in fact, the height of any block level non-replaced element
containing only an inline replaced element.

  ["If it only has inline-level children, the height is the distance
between the top of the topmost line box and the bottom of the bottommost
line box." -  10.6.3]


(References to sections in http://www.w3.org/TR/REC-CSS2, including
Errata of 2001/01/22)


Any enlightenment would be most welcome.

-- 
Regards,
Val Sharp - Edinburgh


Reply via email to