Re: "||" lists of values

On Tue, 27 Aug 2002, Robin Berjon wrote:
> 
> Hi,
> 
> I can't seem to find a place that states whether values described using 
> "||" correspond to lists that are whitespace or comma separated, or both.

It's neither.

In the CSS spec, || means "one or more of these options, in any order". It
doesn't say whether the options are single tokens, multiple tokens,
strings, identifiers, commas, spaces, or whatnot.

Typically, the list will contain just a single type, for example:

   <border-width> || <'border-top-color'> || <'border-style'>

if you decide to include the width and the style, and decide to make them
'medium' and 'solid' respectively, then you have to separate the tokens
using whitespace to make the two tokens parsable as two tokens:

   medium solid

...or

   solid medium

...or

   solid
   medium

...or any number of other such combinations. Note that since a comma is a
token in itself, it should not be included:

   solid, medium

...is three tokens, not two.

If a comma (or slash) is needed, it'll be explicitly listed in the value
definition for the property. See, for instance, 'font' or 'font-family'.

See: http://www.w3.org/TR/REC-CSS2/about.html#property-defs

-- 
Ian Hickson                                      )\._.,--....,'``.    fL
"meow"                                          /,   _.. \   _\  ;`._ ,.
http://index.hixie.ch/                         `._.-(,_..'--(,_..'`-.;.'

Received on Saturday, 31 August 2002 14:40:35 UTC