W3C home > Mailing lists > Public > www-style@w3.org > November 2010

RE: [css3-backgrounds] Should a non-zero border-radius create a new stacking context ?

From: Sylvain Galineau <sylvaing@microsoft.com>
Date: Sat, 20 Nov 2010 16:25:41 +0000
To: Brad Kemper <brad.kemper@gmail.com>
CC: "www-style@w3.org" <www-style@w3.org>
Message-ID: <045A765940533D4CA4933A4A7E32597E2A4D057A@TK5EX14MBXC113.redmond.corp.microsoft.com>
I never said it shouldn't clip to the inner corner curve. That's not at all the point. If the element with border-radius in my original testcase created a new stacking context then the blue box moves below the green one (as it also will if you give the parent opacity < 1, or a transform). It still must clip to the parent's curve within that parent's stacking context.

So no one is questioning whether the element should clip to the border curve. The suggestion is that the non-zero radius would result in a different z-order for the blue box.

________________________________
From: Brad Kemper [brad.kemper@gmail.com]
Sent: Saturday, November 20, 2010 8:09 AM
To: Sylvain Galineau
Cc: www-style@w3.org
Subject: Re: [css3-backgrounds] Should a non-zero border-radius create a new stacking context ?


On Nov 19, 2010, at 6:19 PM, Sylvain Galineau wrote:

It's more composition work.

I'm not sure what you're saying though: is being consistent with inexplicability a goal ?

No, I'm saying that for it to make sense visually (which should be a goal), anything that clips to the inner edge of the border on the sides (as with overflow), should also clip to the inner edge of the border at the corners. That is more important than the fact that the definition of "padding box" did not take into account the shape of the corners, or that the size of the scrollbars might need to either change a little or overlap the border.

Or are you saying that a new stacking context should be created even when border-radius is 0 ?

I don't think I am. I would have liked it if non-visible overflow created a stacking context (agreeing with Simon on that). But since it doesn't, then rounding the corners wouldn't change that. Unless you are saying that having a rounded corner clipping area instead of a strictly rectangular clipping area necessitates changing the stacking context—but I don't see why that would need to be true.

The latter would be a much larger and likely breaking change for the web. One could certainly argue that it's disruptive to change z-ordering as a result of rounding a corner but we do that for opacity for reasons that are not so explicable to authors.

I don't think that is required or wanted here.



________________________________
From: Brad Kemper [brad.kemper@gmail.com]
Sent: Friday, November 19, 2010 2:42 PM
To: Sylvain Galineau
Cc: www-style@w3.org<mailto:www-style@w3.org>
Subject: Re: [css3-backgrounds] Should a non-zero border-radius create a new stacking context ?



On Nov 19, 2010, at 12:43 PM, Sylvain Galineau <sylvaing@microsoft.com<mailto:sylvaing@microsoft.com>> wrote:

Without the creation of a new stacking context, one can construct odd scenarios where a relatively positioned child is clipped to the curve while elements
outside its parent are layered in z-order underneath it. (see attached testcase in latest Firefox 4 Beta).

How is that any odder than the same situation where a relatively positioned child is clipped to a straight side or sharp corner.


It's not  clear to me why this is useful or desirable.

See this attached case, where the sharp-cornered clipping seems inexplicable to someone who doesn't know the mechanics of why it's happening.
Received on Saturday, 20 November 2010 16:26:23 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:34 GMT