[whatwg] Canvas feedback (various threads)

On 2/10/11 7:56 PM, Ian Hickson wrote:
> On Thu, 3 Feb 2011, Boris Zbarsky wrote:
>>
>> It looks like CSS rgba colors with an alpha value of 0 are serialized as
>> rgba() with "0" as the alpha value. in at least Gecko, Webkit, and
>> Presto.
>>
>> It also looks like canvas style color with an alpha value of 0 are
>> serialized as rgba() with "0.0" as the alpha value in Gecko 3.6, Webkit,
>> and Presto.

I have to correct myself.  The above is the behavior in _Chrome_, not in 
all Webkit-based browsers.  In Safari, canvas style colors are 
serialized as the original string they were set to, apparently (so if 
you set it to 0.0 you get 0.0 back; if you set it to 0 you get 0 back, 
and if you set "interoperability" you get "interoperability" back...).

An additional data point is that in the IE9 RC you get 0, just like in 
Firefox 4.

> Given Anne's point (that this is already different in other contexts), and
> given the current deployed interop on this issue

Which is less interop than it seems (due to Safari's behavior), and 
about to disappear completely, since both IE9 and Firefox 4 will ship 
with the 0 instead of 0.0....  :(

> It's another example of why it's important for us to define
> everything, and that we never leave anything up to UAs to decide. :-)

Preaching to the choir, eh.  ;)

-Boris

Received on Thursday, 10 February 2011 20:12:47 UTC