RE: [css3-flexbox] "definite" sizes?

> From: Daniel Holbert [mailto:dholbert@mozilla.com]
> Sent: Thursday, March 01, 2012 1:36 PM
> To: www-style; Alex Mogilevsky; Tab Atkins Jr.
> Subject: [css3-flexbox] "definite" sizes?
> 
> Hi www-style,
> 
> The current Flexbox Layout Algorithm has its behavior conditioned off of
> whether or not sizes are "definite".  So it's clearly important for correctness to
> be able to tell whether or not that term applies to a given size.
> 
> However, the term "definite" isn't defined anywhere, as far as I can tell.
> 
> What precisely does it mean? Clearly it includes e.g. "width: 10px", but what
> about the following:
>    * 50%
>    * calc(10px)
>    * calc(5in + 3em)
>    * calc(intrinsic + 10px)
>    * auto
> 
> Would any of those count as "definite sizes"?

The word came from Tab's text, not sure it is defined elsewhere, but I am using it too for consistency. Here is my understanding of what it is:

"definite" is something that is set to a specific size (such as pixels) or is determined by layout outside of flexbox (such a percent size or auto, where parent layout has specific rules for handling auto).

For example, if a flexbox item in a horizontal flexbox has "height:auto;" and flexbox has "height:100px; flex-align:stretch;", the child's height is "definite" and resolves to parent height minus child's margins, border and padding. If the child is in turn a vertical flexbox, its height is its main size, and it is "definite".

How would this sound as a definition:

<ins>
Some lengths that are inputs to this algorithm may have values that are specified exactly or are resolved prior to application of this algorithm. Such lengths are referred to as <def>Definite</def>.
</ins>

--alex

Received on Monday, 12 March 2012 00:29:34 UTC