W3C home > Mailing lists > Public > whatwg@whatwg.org > May 2010

[whatwg] CSS2 system colors in legacy color values

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Mon, 31 May 2010 22:37:16 -0700
Message-ID: <AANLkTike9-yvKJnGyKrT7j716zx2wIftaxz0zvahXzMu@mail.gmail.com>
On Mon, May 31, 2010 at 2:51 AM, Roger H?gensen <rescator at emsai.net> wrote:
> Just did some tests! It seems that the latest Firefox, Opera, IE, and Chrome
> at least supports fractional percentages.
> So rgb(0%,0%,80.00% equals 0,0,204
> and rgb(0%,0%,80.99% equals 0,0,207
> and rgb(0%,0%,80.50% equals 0,0,205
>
> I wonder why the specs don't mention this support though,
> and I guess that a value of 200% (what, like infared?) would mean twice as
> red as SRGB red (100%),
> and in the case of these browsers they clamp anything higher to 255.

What spec should mention it?  CSS already does, in the CSS3 Values and
Units spec.  A <percentage> is a <number> followed by a '%' character,
and a <number> is a float.

~TJ
Received on Monday, 31 May 2010 22:37:16 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:23 UTC