- From: Robert O'Callahan <robert@ocallahan.org>
- Date: Thu, 17 May 2012 22:19:32 +1200
- To: Alan Stearns <stearns@adobe.com>
- Cc: www-style <www-style@w3.org>
- Message-ID: <CAOp6jLayoGYARYiAbTr3GHMcOfRWbL=5urQq=Zz4oevwLSH3sg@mail.gmail.com>
The dependency of exclusion order, and hence layout, on z ordering is still a problem for us in Gecko. Currently nothing in CSS makes layout depend on z-order, so we don't compute z-ordering until paint time. By adding this new dependency you're making a fundamental change to the architecture of CSS and will require us to make fundamental changes. Maybe there is no alternative, but it sucks. Also, CSS z-ordering is widely agreed to be super-complex and difficult to understand, so making layout depend on it pulls a lot of complexity into layout, and exclusions specifically. This may be unwise. One of the complexities is that parts of the same element can be interleaved in z-order with parts of other elements, so in fact section 3.4 is ambiguous. It is not enough to say "exclusions follow the painting order". You probably want to say something about exclusions being ordered according to the order in which the borders of the exclusion elements would be painted. When you combine this with CSS multi-column and regions, a block-level exclusion element could break and have multiple border-boxes. This entire spec seems to be written on the assumption that there will only be one-border box. It might not be too hard to accumulate all border-boxes into the exclusion region, but the spec needs to be updated to handle that. But worse, with CSS regions, the border-boxes might not all be at the same z-level; I think you could have two exclusion elements whose border-boxes are interleaved in z-order. (E.g. when an element breaks across region boundaries and the second region uses 'z-index' to land somewhere else in the z-order.) If so, then ordering exclusion elements by z-order won't work. Maybe you can rescue the situation by declaring that an exclusion is not an element but something else, that an exclusion element can generate multiple exclusions (corresponding to its multiple border-boxes), and these exclusions can be ordered independently. (You'd need to audit the spec to make sure that the distinction between "exclusion" and "exclusion element" is correctly and clearly made everywhere.) If you do that, you'll need to check carefully to make sure things work when an element's first border-box is an exclusion box for its second border-box and vice versa... Rob -- “You have heard that it was said, ‘Love your neighbor and hate your enemy.’ But I tell you, love your enemies and pray for those who persecute you, that you may be children of your Father in heaven. ... If you love those who love you, what reward will you get? Are not even the tax collectors doing that? And if you greet only your own people, what are you doing more than others?" [Matthew 5:43-47]
Received on Thursday, 17 May 2012 10:20:07 UTC