Re: [css3-flexbox] intuitivity and width computation rules

That is exactly what happens when you have two CSS properties 
competing for the value of the same entity (width: auto and that 
box-flex:2). Result is perfect mess. With full respect to XUL authors
the way they decided to add that functionality is very far from 
the nature of CSS. 

Needless to say that with flex units all this better suits CSS:

container { flow:horizontal; } 
child1 { width: 2*; }
child2 { width: 1*; }
child3 { width: 1*; }

And of course it is human comprehendible. 

-- 
Andrew Fedoniouk

http://terrainformatica.com



-----Original Message----- 
From: Daniel Glazman 
Sent: Wednesday, January 12, 2011 2:37 AM 
To: www-style list 
Subject: [css3-flexbox] intuitivity and width computation rules 
>
>I have played a bit with flexbox recently because I wanted
>to tweak a bit my editor BlueGriffon and base the current
>New Document wizard on CSS3 FlexBox rather than on YUI Grids.
>
>In just a few words: it's *impossible* at this time.
>
>The reason is that the "flexibility" computation, ie the distribution
>of remaining space, is done AFTER the computation of the widths of
>the flexing elements. If one of these elements increases its width -
>for instance a paragraph containing a long text - then the widths
>are counter-intuitive and absolutely useless to Web Designers.
>
>Here's a good example:
>
>   http://glazman.org/forCSSWG/flexbox-test.html
>
>(use Firefox4 beta or WebKit)
>
>Nobody - except the CSS WG itself and I'm not even sure - will ever
>understand why the paragraphs make the first flexing box of the second
>section grow...
>But more important, nobody will ever understand what needs to be done
>to work around this, i.e. go back to the behaviour all web designers
>expect: the first box of the first and second sections should have
>same width whatever the content.
>
>I think we have an architectural issue here. Flexbox cannot be
>used in the most general case on the Web because of that issue; I'm
>close to thinking this module is useless as is.
>
></Daniel>
>--
>W3C CSS Working Group, Co-chair
>
>

Received on Friday, 14 January 2011 02:55:00 UTC