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

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 UTC