W3C home > Mailing lists > Public > www-style@w3.org > February 2010

Re: [cssom] serializing <color>

From: Anne van Kesteren <annevk@opera.com>
Date: Tue, 16 Feb 2010 17:59:27 +0100
To: "Boris Zbarsky" <bzbarsky@mit.edu>, "Tab Atkins Jr." <jackalmage@gmail.com>
Cc: "CSS WG" <www-style@w3.org>
Message-ID: <op.u78b5dyi64w2qv@annevk-t60>
On Tue, 16 Feb 2010 17:51:55 +0100, Boris Zbarsky <bzbarsky@mit.edu> wrote:
> So it sounds like you really want access to the "used color", right?  I  
> have no problem with whatever canonicalization we want for used colors,  
> or even computed ones.  I'm just not convinced that _specified_ colors  
> should be canonicalized.  That would lead to all sorts of weirdness like  
> .style.color not matching the string that appears in  
> getAttribute("style"), for example.

Firefox is broken in that respect already and no other browser keeps those  
consistent either. Another Live DOM Viewer example:

<!DOCTYPE html>
<body style=color:#fff>x

Firefox _manipulates_ the style attribute and gives rgb(255, 255, 255) for  

Opera keeps the style attribute as is and gives #ffffff for .style.color.

Chrome keeps the style attribute as is and gives rgb(255, 255, 255) for  

Anne van Kesteren
Received on Tuesday, 16 February 2010 17:23:31 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:38:32 UTC