W3C home > Mailing lists > Public > www-style@w3.org > May 2010

Re: Fw: RE: [css-flexbox] Summary of planned changes to Flexbox ?Module

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Sun, 9 May 2010 16:30:22 -0700
Message-ID: <r2udd0fbad1005091630zb35e37a6jf275f63ae5a8b74a@mail.gmail.com>
To: robert@ocallahan.org
Cc: "www-style@w3.org" <www-style@w3.org>
On Sun, May 9, 2010 at 3:33 PM, Robert O'Callahan <robert@ocallahan.org> wrote:
> On Mon, May 10, 2010 at 4:46 AM, Tab Atkins Jr. <jackalmage@gmail.com>
> wrote:
>> You can still set min/max-width.  Does that address your needs?  Using
>> flex units means changing from the additive flex model that Flexbox
>> currently describes to an absolute flex model.
> This is actually a problem, as David pointed out.
> Maybe we can solve it using calc()? I.e., "width: calc(200px, 2*)"?

I assume you mean calc(200px + 2*)?  Yeah, that's definitely a
possible solution.

However, the situation David presents doesn't *necessarily* require
additive flex, I believe.  The Firefox toolbar is set up something
like this:


Now, the way it flexes right now is equivalent to this:

urlbar { width: calc(fit-content + 3*); }
searchbar { width: calc(fit-content + 1*); }
input { width: 1*; }

But most of the time, the following will be nearly equivalent:

urlbar { width: 3*; min-width: fit-content; }
searchbar { width: 1*; min-width: fit-content; }
input { width: 1*; }

The difference only becomes noticeable for very small sizes if the
ratio of the intrinsic widths of the urlbar and searchbar are
significantly different from 3:1.  In that case, one bar will start to
flex before the other one as free space becomes available.  Once
you've gotten a decent chunk of free space, though, the difference is
only a couple of pixels.

Received on Sunday, 9 May 2010 23:31:16 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:07:46 UTC