W3C home > Mailing lists > Public > www-style@w3.org > March 2014

[css-counter-styles] Should using the wrong symbols vs. additive-symbols make an @counter-style rule invalid?

From: L. David Baron <dbaron@dbaron.org>
Date: Tue, 25 Mar 2014 18:51:26 -0700
To: www-style@w3.org
Message-ID: <20140326015126.GA30585@crum.dbaron.org>
http://dev.w3.org/csswg/css-counter-styles/#counter-style-system
(section 3.1 and its subsections) describes seven counter styles:

 * 5 of them (cyclic, fixed, symbolic, alphabetic, positional) use
   the 'symbols' descriptor

 * 1 of them (additive) uses the 'additive-symbols' descriptor

 * 1 of them (override) uses neither descriptor

Each subsection of section 3.1 says that a @counter-style rule is
invalid if it is missing the required descriptor, except of course
for 'override', where it says:
  # If a @counter-style uses the override system, it must not
  # contain a symbols or additive-symbols descriptor, or else the
  # @counter-style rule is invalid. 

Further, the definition of the descriptors themselves in
http://dev.w3.org/csswg/css-counter-styles/#counter-style-symbols
(section 3.8) says:
  # The symbols descriptor must be specified if the counter system
  # is cyclic, numeric, alphabetic, symbolic, or fixed, and the
  # additive-symbols descriptor must be specified if the counter
  # system is additive; otherwise, the @counter-style is invalid and
  # must be ignored.

This means that failing to have a necessary 'symbols' or
'additive-symbols' descriptor makes a @counter-style rule invalid,
and having an unnecessary 'symbols' or 'additive-symbols' descriptor
for a rule with 'system: override' makes the @counter-style rule
invalid.

But nothing I see says that having an unnecessary 'symbols' or
'additive-symbols' descriptor for the other six counter styles makes
the rule invalid (that is, having 'symbols' for 'system: additive'
or having 'additive-symbols' for one of the 5 systems that require
'symbols').  This seems like an odd asymmetry.  Is it intentional,
should it be fixed, or am I missing relevant spec text?

-David

-- 
𝄞   L. David Baron                         http://dbaron.org/   𝄂
𝄢   Mozilla                          https://www.mozilla.org/   𝄂
             Before I built a wall I'd ask to know
             What I was walling in or walling out,
             And to whom I was like to give offense.
               - Robert Frost, Mending Wall (1914)

Received on Wednesday, 26 March 2014 01:51:51 UTC

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