W3C home > Mailing lists > Public > public-css-archive@w3.org > November 2017

[csswg-drafts] [css-shapes] Allow new formatting contexts to be sized based on *bounding* float-area.

From: Ian Kilpatrick via GitHub <sysbot+gh@w3.org>
Date: Fri, 10 Nov 2017 18:15:55 +0000
To: public-css-archive@w3.org
Message-ID: <issues.opened-273017156-1510337754-sysbot+gh@w3.org>
bfgeek has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-shapes] Allow new formatting contexts to be sized based on *bounding* float-area. ==
With css-shapes, floats are positioned based on their margin-box. See example-5 in:

They will not try and place themselves based on the "float-area", instead the bounding margin-box.

New formatting contexts however, (`overflow: hidden`, etc) are a different story. It's not exactly clear what the spec intended here.

Currently today in Blinks implementation we will try and size new formatting contexts based on the "float-area". Our implementation uses a previous frame's data, which is completely broken.

In order to do this "correctly" you would have to iterate through every available inline-size, (stepping probably at each pixel?), perform a layout, and check if the block-size of the new FC will fit in the given area.

We (blink) have added a UseCounter for the broken behaviour, are probably going to move to our default sizing/positioning algorithm for new-FCs in the near future.

Given the "correct" behaviour is expensive (requires potentially N layouts - where N is a large number), it might be worth changing the spec to size & position new-FCs similar to how floats currently behave.

This would leave only line-boxes being sized and positioned based on the "float-area". 

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1970 using your GitHub account
Received on Friday, 10 November 2017 18:15:58 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:20 UTC