- From: David Hyatt <hyatt@apple.com>
- Date: Wed, 04 Feb 2009 16:55:14 -0600
- To: "www-style@w3.org List" <www-style@w3.org>
- Message-id: <A8B6ECB5-217D-4447-A046-3D95736EFBE3@apple.com>
I'd like to propose a change to the painting order of overflow objects. In this example: <div style="width:100px;height:100px;background-color:red;margin- bottom:-100px">This text paints on top of the overflow block.</div> <div style="width:100px;height:100px;overflow:hidden;background- color:green;"></div> The overflow block is allowed to interleave with the previous block. Although its background is on top of the previous block, the previous block's text paints on top of the overflow block's background. This is correct according to the current painting order rules, which do not special case overflow. However, this leads to strange renderings, especially when scrolling mechanisms are present. The partial overlapping also makes it more likely that scroll blitting will have to be disabled. I'd prefer to see overflow special-cased such that it does not interleave with other normal flow content by default. I don't think there is any real benefit to be gained by allowing such interleaving. It is also more difficult to encapsulate the painting of the overflow (e.g., if you wanted to optimize it for accelerated compositing) if the overflow block has to break up its painting because of surrounding normal flow content. The above test case does support interleaving in IE8 (standards mode), Firefox and Opera. Interleaving is not the behavior you get in IE7 or WebKit. If this idea appeals to others, I can work on producing the new language for http://www.w3.org/TR/CSS21/zindex.html dave (hyatt@apple.com)
Received on Wednesday, 4 February 2009 22:55:57 UTC