W3C home > Mailing lists > Public > www-style@w3.org > September 2006

[css3-namespace] Case sensitivity and XML namespace in document.

From: <karl@w3.org>
Date: Tue, 05 Sep 2006 05:56:49 -0000
To: www-style@w3.org
Message-Id: <20060905055715.B18694F460@homer.w3.org>

Hi,
This is a QA Review comment for "CSS Module: Namespaces"
http://www.w3.org/TR/2006/WD-css3-namespace-20060828/
2006-08-28
2nd WD

About http://www.w3.org/TR/2006/WD-css3-namespace-20060828/#prefixes

XML Namespaces are case sensitive. "dc:title" is not the same than "DC:title" but CSS Namespaces says:

	[[[
	Namespace prefixes are, like CSS property 
	names, case-insensitive.
	]]]

Then the next requirement saying that

	[[[
	If a namespace prefix or default namespace 
	is declared more than once only the last 
	declaration shall be used.
	]]]

So if we consider the following test case:

<html xmlns="http://www.w3.org/2002/06/xhtml2/"
      xmlns:dc="http://dublincore.org/documents/dcmi-namespace/"
      xmlns:DC="http://foo.example.org/"
      xml:lang="en">
   <head>
     <title>Some Document</title>
	 <style type="text/css">
	    @namespace dc "http://dublincore.org/documents/dcmi-namespace/";
	    @namespace DC "http://foo.example.org/";
	    DC|title {text-align: left;}
	    dc|title {text-align: center;}
	  </style>
   </head>
   <body>
     <dc:title><cite href="urn:isbn:0060006994">Fix-it Duck</cite></dc:title>
     <DC:title>Doctor</DC:title>
   </body>
 </html>

what will be the result and for which element? The spec seems to say that only the second one has to be considered, then

	@namespace DC "http://foo.example.org/";

but which one of the two values after is applied and to which elements. Is it the second one

	dc|title {text-align: center;}
 
How is it applied to the document? Only "dc:title"?
Does that mean  that some elements will be impossible to style?





-- 
Karl Dubost - http://www.w3.org/People/karl/
W3C Conformance Manager, QA Activity Lead
   QA Weblog - http://www.w3.org/QA/
      *** Be Strict To Be Cool ***
Received on Tuesday, 5 September 2006 05:57:22 GMT

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