W3C home > Mailing lists > Public > www-style@w3.org > June 2005

Re: [CSS2.1] Counters

From: Staffan Mhln <staffan.mahlen@comhem.se>
Date: Thu, 16 Jun 2005 09:38:20 +0200
To: "L. David Baron" <dbaron@dbaron.org>
CC: www-style@w3.org
Message-ID: <42B1488C.28959.3544E5E@localhost>

On 15 Jun 2005 at 9:42, L. David Baron wrote:
> > to something like:
> > "
> > The scope of all counters used in a document are reset to 0 at the 
> > root element unless explicitly set to a different value. Each element
> > that has 'counter-reset' for a counter creates a new scope that 
> > includes its descendants.
> > "
> 
> This would not only break Hn numbering, but would also cause lists
> numbered using counters() to all have an additional "0." at the
> beginning of the number, e.g. "0.10.3" instead of "10.3".
> 

Ok that makes sense i suppose. Just to make sure i get it, you want
to allow headings to be scope-generating without being nested in the
document, rather than use the list-method where a common ancestor
is needed?
h1 {counter-reset: h2 0 h3 0 h4 0...}
h2 {counter-reset: h3 0 h4 0...}

The second problem could perhaps be addressed in the
definition of the counters function, by making it not include the
"initital" reset.

 /Staffan
Received on Thursday, 16 June 2005 07:38:28 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:54:37 GMT