W3C home > Mailing lists > Public > www-style@w3.org > December 2015

Re: [css-sizing][css-flexbox] intrinsic min/max-width/height values and percentage children

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Tue, 1 Dec 2015 13:38:42 -0800
Message-ID: <CAAWBYDCYDP8NEqYsUBRRXvne_D4miXeY1svK2fi+92Fo=tPVFA@mail.gmail.com>
To: fantasai <fantasai.lists@inkedblade.net>
Cc: Daniel Holbert <dholbert@mozilla.com>, Greg Whitworth <gwhit@microsoft.com>, www-style list <www-style@w3.org>
On Tue, Dec 1, 2015 at 1:35 PM, fantasai <fantasai.lists@inkedblade.net> wrote:
> Wrt optimization, I think you can optimistically assume that most
> cases won't be controlled by the min-size, and only do extra work
> if that isn't so.

In particular, the *normal* path for work here is (1) lay out
according to width/height, (2) calculate the min-content width/height
and check whether or not you need to make a width/height adjustment to
bring it into conformance.

Assuming you either (a) don't use percentages in the children, or (b)
don't violate the min-width/height constraint, no additional work is
done.  It's only when you have a % child *and* violate
min-width/height that you have do to a second layout pass, because the
% children will change size.

~TJ
Received on Tuesday, 1 December 2015 21:39:30 UTC

This archive was generated by hypermail 2.4.0 : Monday, 23 January 2023 02:14:55 UTC