W3C home > Mailing lists > Public > www-style@w3.org > August 2011

Re: [css] Proposal: making Shorthand Hex Colors even shorter (16 grayscale shades)

From: L. David Baron <dbaron@dbaron.org>
Date: Tue, 2 Aug 2011 14:31:49 -0700
To: Markus Bruch <macinfo@arcor.de>
Cc: www-style@w3.org
Message-ID: <20110802213149.GA1463@pickering.dbaron.org>
On Sunday 2011-07-31 13:34 +0200, Markus Bruch wrote:
> Hi, I'm new to this list, so please forgive if this topic has been
> talked about before.

One note:  please start a new thread by emailing a new message
rather than replying to an existing one and changing the subject,
which makes it show up in the middle of some other unrelated thread
in many mail clients.

(Or, if you insist on replying, you need to delete the In-Reply-To
and References headers.)

> I would suggest that for a specific set of 16 grayscale shades,
> to reduce the rgb-values to one single character:
> 
> 	.gray { color: #ccc; }
> 
> to:
> 
> 	.gray { color: #c; }
> 
> In addition to it's only marginal bandwith or space saving it
> would have the benefit of being concise and easily visible to
> the reader, that this code assigns a grayscale color (from a
> set of 16 shades, #0 - #f).

I tend to think any benefit in space or typing here is not worth the
potential confusion for those reading style sheets written by
others.  (I'm particularly hesitant to add new syntax that's hard to
search for with search engines -- somebody who doesn't know what
hsl() is can search for it; that's a good bit harder in this case.)

-David

-- 
𝄞   L. David Baron                         http://dbaron.org/   𝄂
𝄢   Mozilla Corporation               http://www.mozilla.com/   𝄂
Received on Tuesday, 2 August 2011 21:32:15 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:43 GMT