Re: [css21] height: [percent]

----- Original Message ----- 
From: "Andrew Fedoniouk" <news@terrainformatica.com>
To: <www-style@w3.org>
Sent: Friday, March 03, 2006 8:58 AM
Subject: [css21] height: [percent]


>
> Question regarding computation of height attribute given in percent units.
>
> Consider following html:
>
> <html><body>
> <p><img style="height:50%;"src="..." /></p>
> </body></html>
>
> I didn't find any UA which follows rule [1]:
>
> "The percentage is calculated with respect to the height
> of the generated box's containing block. If the height of the containing
> block is not specified explicitly (i.e., it depends on content height), 
> and this
> element is not absolutely positioned, the value computes to 'auto'"
>
> All known me UAs set height of the image equal to 50% of height
> of the body element but as far as I understand wording above
> it should be set to 'auto' here.
>
> Question: what height this image should have?

As I see is not clear in wich case we are. I hope some other helps:

Read:
http://www.w3.org/TR/CSS21/visudet.html#inline-replaced-height

The confuse point is when the spec says that the computed value is auto, as 
you say.

> [1] http://www.w3.org/TR/CSS21/visudet.html#the-height-property

Received on Friday, 3 March 2006 10:02:44 UTC