Re: CSS Opacity

Hello,

Zoffix Znet schrieb:
> I think it is very inconvenient that when you set opacity on an element
> you cannot make descendants opaque.

> You want to show a photo in the middle of the page and make the rest of
> the page semi-transparent.
> 
> body { opacity: .5; }
> 
> Will make the photo semi-transparent as well.
> 
> #photo { opacity: 1; }
> 
> Will not fix this.

Maybe values > 1 should be allowed for opacity? For example:

#photo { opacity : 2; }

Would mean that the element, whose pixels have an "effective" opacity of
0.5 would have the "effective" opacity of its pixels doubled, to 1.0,
meaning they are rendered with double opacity, which is then halved by
the body element and appears thus just plain opaque to the viewer.

I don't know if this could be implemented as graphics libraries often
"clamp" the colour values to [0;1]...


-- 
pascal

Received on Sunday, 29 April 2007 10:18:11 UTC