W3C home > Mailing lists > Public > www-style@w3.org > October 2009

Re: [css3-background] possibly too late for last call, but: background-opacity?

From: Simon Fraser <smfr@me.com>
Date: Thu, 15 Oct 2009 13:25:01 -0700
Cc: Brad Kemper <brad.kemper@gmail.com>, www-style@w3.org
Message-id: <311EF751-7D18-454F-83F8-0D8C0AD65030@me.com>
To: Lee Owen <fleeboy@gmail.com>
On Oct 15, 2009, at 1:15 PM, Lee Owen wrote:

> Thanks for your reply and your drop-shadow proposal page! Thats a  
> very flexible approach.
>
> Could you target specific background images in a multi-background  
> element? For example:
>
>  opacity:0.5; apply-to(opacity, background-image(1,2,4) + background- 
> color);
>
> and would these properties be able to be animated?

I suggested previously a separate background-image-opacity, which  
handles multiple
background images:
<http://markmail.org/message/motzwy5qmq7mhzkn#query:+page:1+mid:kqg2pwb3wl7v2o7m+state:results 
 >

A property like that would be easy to implement, very easy to animate,  
and make doing
image cross-fades really simple. The apply-to() proposal seems a lot  
more complex,
and harder to fit into the animation engine.

More generally, you can already do color-opacity with rgba() colors,  
so you only really
need separate control of opacity for image assets (and alpha-PNG  
doesn't cut it when
you want to animate the opacity). Another approach would be to have  
some kind
of image effect syntax that wraps images in a filter effect, but that  
is still logically treated
like an image:
   background-image: transparency(url(foo.jpg), 0.5);

Simon
Received on Thursday, 15 October 2009 20:25:40 GMT

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