W3C home > Mailing lists > Public > www-style@w3.org > April 2011

Re: [css3-flexbox] Best way to denote flexible lengths

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Thu, 14 Apr 2011 09:42:27 -0700
Message-ID: <BANLkTikoC-kE6wCMqkKux=iQkUG_64eoiA@mail.gmail.com>
To: Brad Kemper <brad.kemper@gmail.com>
Cc: Alex Mogilevsky <alexmog@microsoft.com>, www-style list <www-style@w3.org>
On Wed, Apr 13, 2011 at 11:14 PM, Brad Kemper <brad.kemper@gmail.com> wrote:
> On Apr 13, 2011, at 5:29 PM, Tab Atkins Jr. wrote:
>> On Wed, Apr 13, 2011 at 5:22 PM, Alex Mogilevsky <alexmog@microsoft.com> wrote:
>>> I don't like the idea of width/height taking space-separated lists. I would rather have a flex function.
>>> Given a choice between flex(1,0,auto) with commas and fixed set of arguments and flex(auto 1 0) with space separated arbitrary order, I think I would clearly prefer any-order version...
>> Okay, then I'll change the draft to accept the 'fr' unit and the
>> 'flex()' function with space-separated any-order arguments.  Sound
>> good?
> I'm confused. 'flex(auto 1 0)' is the same as 'flex(auto 0 1)' or 'flex(1 auto 0)'?

As Alex says, the pos-flex and neg-flex, being both integers, must be
ordered.  The obvious order is that the first integer is pos-flex and
the second is neg-flex, so "flex(auto 1 0)" would be equivalent to
"flex(1 auto 0)", "flex(1 0 auto)", "flex(1 auto)", "flex(auto 1)",
"flex(1)" and "flex(auto)".  (I think that's the most prolific
combination for variants, because it matches the defaults.)

Received on Thursday, 14 April 2011 16:43:09 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:38:45 UTC