- From: James Elmore <James.Elmore@cox.net>
- Date: Sun, 24 Jun 2007 16:33:53 -0700
- To: www-style@w3.org
leslie.brown@evidian.com wrote: > I like the idea, which corresponds to what many of > us find quasi-impossible to achieve without tables. > > Could it also be achieved via a "blocky" variant > of float? > . Same markup > . Styling > div#leftbar { float: left, blocky } > div#right { float: right, blocky } > div#content { float: blocky } > where "blocky" says: the floated element extends > to the full height of its containing element after > all the content of the latter has been resolved. > > This would, for example, allow you to set the > background of a sidebar on the sidebar itself > rather than having to kludge it on the container > (so easy with table cells!). > > Minimal impact on incremental rendering (?). > > I'm guessing that if the container has other content > without "float: blocky" defined it should be treated > as though it was a single blocky div, i.e. fills the > remaining horizontal space and stretches the container > if it's taller than the floated siblings. > > So, in fact (just thinking aloud here) you could > specify "float: blocky" (or "float-strategy: blocky"?) > on the containing element instead and get fairly > reasonable results in older browsers. This would > also avoid the confusion that might arise if a div > contained some floats with and some without the > blocky parameter. > > And I wonder if a "blockx" variant that triggers > the same automatic filling along the x axis rather > than the y axis might be useful for languages where > text flows vertically rather than horizontally. > Of course you'd then need float:top and > float:bottom. > > > Les Brown Please see my response to Andrew Fedoniouk. (Sorry if I misspelt your name, Andrew.) I prefer setting layout parameters on blocks to attempting to float them. With floats, what you get may not look anything like what you expect, depending on screen width, UA settings, etc. There are many ways to lay out screens and pages while being sure your elements go where you wish them. What I suggested (probably at too much length) in my response to Andrew is just the simplest way I considered to lay out blocks -- by combining horizontal and vertical 'stacking' or 'lists' of elements. It involves minimal additions to CSS (or HTML, depending on your viewpoint) and most of the code already exists in UAs, for tables, and might be repurposed for my proposed horizontal layouts. -- James Elmore 22162 Windward Way Lake Forest, CA 92630 Home (949) 830-9534 Email James.Elmore@cox.net
Received on Sunday, 24 June 2007 23:34:03 UTC