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

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

From: Boris Zbarsky <bzbarsky@MIT.EDU>
Date: Mon, 09 Jul 2012 18:27:31 -0400
Message-ID: <4FFB5AD3.7010204@mit.edu>
To: www-style@w3.org
On 7/9/12 6:14 PM, Simon Sapin wrote:
> I did not though of these because, in my implementation, "treated as if
> it had 'display: none'" just means removing/dropping a box object. I
> never keep around a box with the used value set to 'none'.

Sure; the point is that the computed value doesn't tell you there will 
be a box.

> Anyway, back to the original topic: it is unclear to me whether such
> boxes should affect counters. I probably have bugs in WeasyPrint such as
> a box that can increment a counter before being "removed" in a later step.

Yeah, all the spec says is:

   An element that is not displayed ('display' set to 'none') cannot
   increment or reset a counter.

(CSS2.1 section 12.4.3).  That's not much to go on....

I believe in Gecko such elements don't affect counters (because we never 
create such boxes to start with, but even if we did counter numbering 
has to deal with dynamic removals in a non-print context, so removing 
the boxes would renumber the counters).

Received on Monday, 9 July 2012 22:28:00 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:39:01 UTC