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

Re: [css3-color] #rrggbbaa annotation

From: Alberto Lepe <dev@alepe.com>
Date: Wed, 31 Mar 2010 11:25:37 +0900
Message-ID: <q2r8c9249b71003301925qcc9e937at8814fbf0503406a7@mail.gmail.com>
To: www-style list <www-style@w3.org>
On Sat, Mar 27, 2010 at 11:42 AM, Brad Kemper <brad.kemper@gmail.com> wrote:
> But besides that, most tools with color pickers these days let you copy a hex value from them to paste in somewhere else. For instance, I sometimes use the color picker in PhotoShop to pick the color, then copy and paste the hex value into a text editor or Safari's developer tools. PhotoSHop also shows RGB, but that is in three different fields, so it would be three times the work to copy/paste (I do sometimes manually type the values and add an alpha component for rgba() though, but that takes an extra second or so!).
> I like the idea of #RRGGBBAA, and would have no problem picking the AA as hexadecimal.
> On Mar 26, 2010, at 5:16 PM, Tab Atkins Jr. wrote:
>> On Fri, Mar 26, 2010 at 5:11 PM, David Singer <singer@apple.com> wrote:
>>> seems like if you expect to have colo(u)rs change, or more particularly you find the same constant several times in your code, you want to define your own named colo(u)rs, and then change one definition...(or use a variable, or something, waffle waffle...)
>> True, CSS Variables would solve a lot of these problems.  If I only
>> had to define colors once, and then could refer to them by name, it
>> wouldn't be nearly as big of an issue.  Variables let you sweep a lot
>> of pain under the carpet.
>> ~TJ

Patrick Garies wrote:
> I've never seen any program represent opacity as anything other than a
> decimal number or percentage

I agree that many applications out there uses alpha channel as a
percentage, however there are some others that express it in a 0-255
range (evenmore, also in HEX values).

[1] My favorite: Inkscape. As you can see in this screenshot:


at the bottom-right corner, the #rrggbbaa annotation is used. Also
note the transparency range.

[2] using #rrggbbaa annotation:
    Google Charts API
    Java Synth Look and Feel
    3DMLW (3D Markup Language)
    GML (Graph Modeling Language)
    iCal for Mac (in theme files)
    Maemo (Nokia)
    gbui for JME (Java Game engine), based in CSS
    Qt UI framework
    xine (OSD config)
    xmCHART for FileMaker Pro
    skEdit (themes)
    (and may other...)

[3] using #aarrggbb annotation:

    Microsoft IE in the gradient filter:

filter: progid:DXImageTransform.Microsoft.gradient(startColorstr=#7FC2C2C2,endColorstr=#7FC2C2C2);

    Color annotation in the XAML language (MS).

[4] Color transparency in VB, C++, Delphi and other languages are
expressed in 0-255.

With this, I would like to state two things:
1) alpha channel with values 0-255 is also common.
2) #rrggbbaa is not a new concept and is widely used and documented.
Received on Wednesday, 31 March 2010 02:26:14 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:07:44 UTC