- From: Anton Prowse <prowse@moonhenge.net>
- Date: Mon, 21 May 2012 19:17:02 +0200
- To: www-style@w3.org
- CC: Boris Zbarsky <bzbarsky@MIT.EDU>
On 21/05/2012 14:36, Boris Zbarsky wrote: > On 5/21/12 1:26 AM, fantasai wrote: >>>> What effect would this have on Block Layout margin-collapsing, which >>>> assigns special meaning to a min-height other than 0? >>> >>> Does it assign that meaning to the computed value or the used value? >>> >>> Seems like the right thing to do is to have the special meaning >>> assigned to used value, no matter what the actual computed value >>> here is. >> >> Computed value. The spec is very clear that margin collapsing is >> based entirely on computed, not used, values. > > Why? I /think/ it's to do with min-height and max-height. 10.7 requires you to treat the result of the "first pass" of the used height calculation as tentative, and re-run the calculation once or twice more if min-height and/or max-height constraints are not satisfied. By making margin collapsing depend on computed values, we guarantee that the margin collapsing relationships are not re-determined during the second and third passes. Without that, I think we could either end up in circular situations where the re-calculation of margin collapsing causes the constraint to not be satisfied the next time either, or else end up with an undesirable final rendering because the height ends up being bigger or smaller than it "ought to be". (On the face of it, though, it does feel like margin collapsing – being a part of layout – ought to depend on used values. I guess the problem is that you've got various aspects of layout with complex interactions, and it's hard to spec how you end up at the result without using such simplifications; the barrier is editorial rather than technical, I think.) Cheers, Anton Prowse http://dev.moonhenge.net
Received on Monday, 21 May 2012 17:17:54 UTC