W3C home > Mailing lists > Public > www-style@w3.org > September 2008

Re: [CSS21] display:block nested inside display:inline = display:inline-block ?

From: Brady Duga <duga@ljug.com>
Date: Sun, 7 Sep 2008 08:42:59 -0700
Cc: Brady Duga <duga@ljug.com>, "www-style@w3.org" <www-style@w3.org>
Message-Id: <80F93CE6-2493-4E85-8ABA-4DDA014E40F0@ljug.com>
To: Anton Prowse <prowse@moonhenge.net>


On Sep 7, 2008, at 2:48 AM, Anton Prowse wrote:

>
> I may just be being unobservant but I can't seem to find anything in  
> the CSS2.1 spec stating the formatting behaviour when an element  
> with display:block is the child of an element with display:inline.

See section 9.2.1.1, specifically:

When an inline box contains a block box, the inline box (and its  
inline ancestors within the same line box) are broken around the  
block. The line boxes before the break and after the break are  
enclosed in anonymous boxes, and the block box becomes a sibling of  
those anonymous boxes. When such an inline box is affected by relative  
positioning, the relative positioning also affects the block box.

--Brady
Received on Sunday, 7 September 2008 15:43:58 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:55:12 GMT