W3C home > Mailing lists > Public > www-style@w3.org > July 2012

Re: [css3-lists] Where can the counter() function be used?

From: Simon Sapin <simon.sapin@kozea.fr>
Date: Thu, 05 Jul 2012 20:45:19 +0200
Message-ID: <4FF5E0BF.2050009@kozea.fr>
To: Simon Fraser <smfr@me.com>
CC: "www-style@w3.org list" <www-style@w3.org>
Le 05/07/2012 19:36, Simon Fraser a crit :
> We recently got a WebKit bug filed that the counter() function didn't
> work in animation-delay; the author was trying something like:
>
> animation-delay: counter() + "s";
>
> So the question is: where can counter() be
> used? http://www.w3.org/TR/css3-lists/  shows it being used in the
> content: property, but is that the only place? Should the spec say
> what it's applicability is?

css3-lists still should says something about this, but CSS 2.1 does:

http://www.w3.org/TR/CSS21/syndata.html#counter
> In CSS 2.1, the values of counters can only be referred to from the
> 'content' property.

This implies that some CSS 3 properties could also accept counter() but, 
I think, only if there are defined to. GCPMs string-set does so:

http://dev.w3.org/csswg/css3-gcpm/#string-set


animation-delay however is defined to accept <time>#, and <time> only 
accepts a dimension token. (By the way css3-animations should probably 
have a reference to css3-values to define <time>.)

Regards,
-- 
Simon Sapin
Received on Thursday, 5 July 2012 18:45:50 GMT

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