W3C home > Mailing lists > Public > www-style@w3.org > January 2015

Re: Extended shorthand for hex colours

From: Marat Tanalin <mtanalin@yandex.ru>
Date: Thu, 22 Jan 2015 17:39:26 +0300
To: Ryan Williams <email@ryanwilliams.co.uk>, "www-style@w3.org" <www-style@w3.org>
Message-Id: <2847351421937566@web17h.yandex.ru>
22.01.2015, 16:50, "Ryan Williams" <email@ryanwilliams.co.uk>:
> Hexadecimal notation is commonly used for defining colours in CSS, but the shorthand is lacking.šRight now we can use #CCC which would be expanded to #CCCCCC, but that's pretty much it.
> Wouldn't it be nice if we built upon the principles of the existing shorthand -- repeating the defined characters -- to provide more options?
> For example:
> 1. #Cšexpands to #CCCCCC
> 2. #C3šexpands toš#C3C3C3
> 3. #CCC expands toš#CCCCCC
> These two extra shorthand formats would allow a lot of hex colours to be typed and/or transmitted across networks more efficiently.
> I don't think it'd make sense to allow for four- or five-character shorthand, as the defined characters could not be repeated in full.

Has already been proposed:

Received on Thursday, 22 January 2015 14:39:59 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:50 UTC