Re: Implementation of Inset Box Shadow on image elements

Background gradients should remain background.

Inset drop shadows should be a z-index higher than the element on  
which it is applied, not just text, but images, object, embeds as  
well. If a developer want the inset shadow to appear behind the  
element, like showing thru a semi transparent element, they should  
create the effect with background image (including background image  
gradient, because it is, in effect, a background.

For shadows without hte inset keyword, the shadow should be of a  
zindex lower, and otherwise the shadow from one letter may overlap the  
the next letter in a series of characters.

I do think the spec needs to be clarified in the case of inset shadows  
as the implementation is not what would be expected. The inset shadow  
on images is behaving as a background image not  a foreground inset  
shadow.

-Estelle
http://standardista.com

On Jul 27, 2010, at 12:12 PM, fantasai wrote:

> On 07/27/2010 12:05 PM, Zack Weinberg wrote:
>> fantasai<fantasai.lists@inkedblade.net>  wrote:
>>
>>> On 07/27/2010 11:29 AM, divya manian wrote:
>>>>
>>>> The reason I posted here was I think it is practical to have inset
>>>> box-shadow ON TOP OF the image rather than below the image, despite
>>>> what the spec says. I think for image elements inset box-shadow is
>>>> not practical otherwise. inset box-shadow would be of great use if
>>>> only for this issue.
>>>> ...
>>>> My view is, the spec should be altered to allow image  to show  
>>>> below
>>>> an inset box-shadow when an inset box-shadow is specified on the
>>>> image element. There is no use-case for the other case where the
>>>> inset box-shadow is behind the image.
>>>
>>> That's an interesting point. Perhaps it makes more sense for the
>>> inset shadow to be on top of the content in *all* cases, not just
>>> for replaced elements?
>>
>> I proposed something similar (not the same, though) in
>> http://lists.w3.org/Archives/Public/www-style/2010Apr/0339.html and
>> Simon Fraser said it would break existing webpages so I gave up.
>
> You proposed also changing the stacking order of borders.
> That's definitely going to break stuff, given that's how
> things have always worked. Changing the stacking order of
> inset box shadows doesn't seem like it would break much,
> though -- it's a very new feature that hasn't even made
> it to CR yet.
>
>> It does seem like drawing inset shadows on top is more
>> likely to be what authors want.
>
> Unless they're trying to fake background gradients, which
> we'll be adding as a proper feature anyway, I think I would
> agree. Moreover, I'd place it over the zeroth z-index layer,
> just underneath z-index: 1, so authors can pop things out
> if they want to.
>
> ~fantasai
>

Received on Tuesday, 27 July 2010 21:02:40 UTC