W3C home > Mailing lists > Public > www-style@w3.org > October 2003

Re: [CSS2.1] Visual formatting model: Floats and Positioning

From: Ian Hickson <ian@hixie.ch>
Date: Fri, 31 Oct 2003 15:53:43 +0000 (UTC)
To: fantasai <fantasai@escape.com>
Cc: www-style@w3.org
Message-ID: <Pine.LNX.4.58.0310311541290.25431@dhalsim.dreamhost.com>

On Tue, 21 Oct 2003, fantasai wrote:
>
> I can't think of any cases where clearance would cause the element
> to go up, so "typically" should not be there to imply that there
> are some.

   <block-a><float/></block-a>
   <block-b/>

   * { border: solid; } /* assume border is present but infinitesimal */
   float { height: 3em; }
   block-a { margin-bottom: 2em; }
   block-b { margin-top: 2em; }

The clearance on block-b is -1em, so the clearance moves the element up
by one em (relative to where it would be if the margins didn't collapse
but the clearance was 0 -- clearance first uncollapses the margins (per
the rules in 8.3.1) and then moves the block relative to where that box
ends up after uncollapsing).

-- 
Ian Hickson                                      )\._.,--....,'``.    fL
U+1047E                                         /,   _.. \   _\  ;`._ ,.
http://index.hixie.ch/                         `._.-(,_..'--(,_..'`-.;.'
Received on Friday, 31 October 2003 10:53:44 GMT

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