W3C home > Mailing lists > Public > www-style@w3.org > December 2009

Re: breaking overflow

From: Brad Kemper <brad.kemper@gmail.com>
Date: Thu, 31 Dec 2009 08:46:49 -0800
Message-Id: <D203685D-EAD3-4DD4-B706-B63CCFF4D4A8@gmail.com>
To: James Hopkins <james@idreamincode.co.uk>
Cc: Anton Prowse <prowse@moonhenge.net>, www-style <www-style@w3.org>, "Tab Atkins Jr." <jackalmage@gmail.com>, Niels Matthijs <niels.matthijs@internetarchitects.be>
On Dec 31, 2009, at 6:18 AM, James Hopkins <james@idreamincode.co.uk>  
wrote:

> My point being, is that CSS has never featured an established,  
> adequate mechanism for clearing floats in this manner.

CSS has the 'clear' property for clearing floats. It works pretty well  
for the types of floats envisioned when the 'float' property was  
created (for pictures, pull quotes, drop caps, etc. and not so much  
for full page layouts with floats inside other floats).

> Up until now, authors have been forced to adopt a workaround borne  
> out of findings from authors (generated content), or use properties  
> for the sole purpose of utilizing that property's side-effect (BFC).

We authors have adopted this workarounds because our use of floats in  
this way is itself a workaround, due to the lack of other, more  
sanctioned ways of laying out page content. As the  new CSS3 layout  
methods are implemented and become practical choices for us, these  
hacks will be less needed.

> Creating a control that could establish a BFC and includes no other  
> behavioral characteristics, is what's lacking here.

Yes, it does seem like a useful control, at least in the relatively  
short term, and I wouldn't think it'd be that hard to implement  
quickly (once there is concrete proposal of what form it should take).  
But I'm not an implementor, so I can't say for sure.

> Also, current methods are wholly unintuitive to authors learning  
> CSS; adding a property named 'float-contain' (or something along  
> those lines) would provide a far greater clue to authors as to  
> exactly what that control does.

Hmm. What would the value of that property be? CSS tends to shun  
simple Boolean values like true|false or yes|no. Also, it's not just  
about clearing floats; it's also about non-collapsing margins (and  
maybe other uses too?).
Received on Thursday, 31 December 2009 16:47:29 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 22 May 2012 03:47:12 GMT