- From: fantasai <fantasai.lists@inkedblade.net>
- Date: Tue, 17 Feb 2009 12:56:49 -0800
- To: Brad Kemper <brad.kemper@gmail.com>
- CC: "www-style@w3.org" <www-style@w3.org>
Brad Kemper wrote: > > > On Feb 12, 2009, at 4:40 PM, fantasai wrote: > >> Robert O'Callahan wrote: >>> Tab Atkins Jr. wrote: >>> > ... >>> BTW they have "inset" too. What "inset" should do with border-images >>> is another kettle of fish... >> >> Invert the alpha values of the mask. > > My view, as stated before, is that "inset" shadows should have nothing > to do with image-border. They are a decorative effect on the padding box. > > Imagine a box with a thick border and a thick inset shadow. It looks a > little like a frame casting a shadow through a cut out space onto a > surface below. Now replace the border with an image of a straight-edged > picture frame that followed the same edges. Wouldn't you still expect > the cut-out effect of the padding box to be the same? If you you inset > the image of the border, you end up with a completely different area > being cut out (unlike with outer shadows). The same thing is true of outer shadows. Look at the diamond border in the draft, for example. Imagine an outer shadow on that. Now imagine an inner shadow. Now consider what we're proposing to do. Putting an outer drop-shadow on the border-box would be wrong. Similarly putting an inner drop-shadow on the padding-box would be wrong. Neither the inner nor the outer edge is rectangular. Drop-shadowing the image based on alpha values would give a drop-shadow on the border image itself, which might look ok but isn't the same effect as you typically get with box-shadow. And clipping that shadow within the padding box would look wrong. > And I think you must have been kidding about inverting the alpha values, > but I didn't see a winking emoticon. Inverting the mask would result in > solid shadow in all the areas that were transparent, and transparent > areas in all the areas that were solid, and perfectly straight outer > edges, regardless of blur. A real inset shadow draws shadows in > completely different places. Yeah. The more I think about this, the more impossible it seems to get it right. ~fantasai
Received on Tuesday, 17 February 2009 20:57:29 UTC