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

Definition of "rule"?

From: Hakon Lie <howcome@w3.org>
Date: Sat, 26 Jul 1997 22:19:14 +0200 (MET DST)
Message-Id: <199707262019.WAA27943@online.no>
To: "E. Stephen Mack" <estephen@emf.net>
Cc: www-style@w3.org
E. Stephen Mack writes:

 > The CSS1 spec defines a "rule" as "a declaration and its
 > selector."
 > 
 > So, given this style sheet:
 > 
 > H1, H2, H3: { color: white; background: blue; }
 > 
 > is that one rule, two rules, three rules, or six rules?

(minor point, the first colon should be omitted in the above example:

   H1, H1, H3  { color: white; background: blue; }

We're here looking at six rules that have been grouped with the
selector grouping mechanism (commas) and the declaration grouping
mechanism (semi-colons). 

 > I'm fairly new to style sheets and in reading through the spec,
 > I couldn't determine from the section on grouping or from
 > context what the correct answer is.

Noted, thanks.

 > I'm also stunned by how wildly different a style sheet
 > can be interpreted by Navigator 4.01, IE 3.02, and IE 4.0 platform
 > preview 2 on my Windows 95 system.

This is indeed a concern and some people have proposed temporary
reliefs [1] until implementations are aligned.

[1] http://www.verso.com/agitprop/css/

Regards,

-h&kon

H      k   o   n      W   i   u   m       L   i   e
howcome@w3.org   W o r l d   Wide  W e b  Consortium
inria # FRANCE http://www.w3.org/people/howcome
Received on Saturday, 26 July 1997 16:19:19 GMT

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