W3C home > Mailing lists > Public > w3c-wai-gl@w3.org > April to June 2006

Re: CSS Parsed Unambiguously

From: Christophe Strobbe <christophe.strobbe@esat.kuleuven.be>
Date: Mon, 12 Jun 2006 16:36:07 +0200
Message-Id: <>
To: <w3c-wai-gl@w3.org>

At 16:06 12/06/2006, Chris Ridpath wrote:
>Christophe wrote:
>>Because of the error handling rules at the second level, it seems to me 
>>that only correct grammar is necessary for a CSS stylesheet to pass SC 
>>4.1.1. However, anything that does not pass at the second level 
>>(according to the most recent CSS specification in your baseline) is 
>>outside the baseline. Does this make sense?
>I think I understand. If you follow this syntax then you pass:
>For example this would fail (missing semicolon):
>H1 {
>  font-weight: bold
>  font-size: 12pt

Fails because it is not written according to the grammar of CSS2.

>This would pass (unknown declaration 'rotation' ignored):
>H1 {
>color: red;
>rotation: 70minutes

Yes, this would pass.

>This would fail (units for '3' not specified):
>IMG { border-width: 3 }

As far as I know, this is written according to the grammar of CSS2 but the 
style declaration is ignored because of an illegal value. Conforming user 
agents must ignore the style declaration, so there's no ambiguous data 

This example also shows the limitation of SC 4.1.1 when applied to CSS. 
Suppose you had the following style rules (instead of the border-width 

body { background: white; color: black; }
h1 { background: black; color: whitd; } /* reverse the colours, but with 
typo in 'white' */

In this case, user agents must ignore the foreground colour for h1, so h1 
inherits its foreground colour from an ancestor element, in this case body, 
so text is black on black. (Which is what I get in Mozilla, Firefox, Opera 
and Internet Explorer.)



Christophe Strobbe
K.U.Leuven - Departement of Electrical Engineering - Research Group on 
Document Architectures
Kasteelpark Arenberg 10 - 3001 Leuven-Heverlee - BELGIUM
tel: +32 16 32 85 51

Disclaimer: http://www.kuleuven.be/cwis/email_disclaimer.htm
Received on Monday, 12 June 2006 14:36:29 UTC

This archive was generated by hypermail 2.4.0 : Thursday, 24 March 2022 21:07:45 UTC