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

[whatwg] return lowercase hex values for fillStyle and strokeStyle

From: Nicholas Shanks <contact@nickshanks.com>
Date: Thu, 10 May 2007 08:02:52 +0100
Message-ID: <2A249362-9FD2-4CBC-8F30-1C2CDD43D4C7@nickshanks.com>
On 10 May 2007, at 07:31, Ian Hickson wrote:

> On Tue, 29 Aug 2006, Anne van Kesteren wrote:
>>
>> Instead of returning an uppercase six digit hex value I suggest
>> returning a lowercase value for compatibility with what UAs  
>> (including
>> IE) currently do for CSS already and what Mozilla already does for
>> <canvas>.
>
> Done.
>
> On Tue, 5 Sep 2006, Christoph P?per wrote:
>>
>> It may be the right decision on compatibility grounds, but other than
>> that lowercase hexadecimal digits (0-9, a-f) are almost always a bad
>> choice, because a, c and e have no ascenders like every hindu-arabic
>> decimal digit has and thus make the number harder to read. This
>> obviously does not apply to fonts with old-style numerals aka. text
>> figures, where 0, 1 and 2 have neither ascenders (like 6 and 8) nor
>> descenders (like 3, 4, 5, 7 and 9), but those are rather unlikely  
>> to be
>> used in a programming environment.
>
> You can use uppercase letters when setting, which is where you're most
> likely to see this. It only affects the getter.
>
> I think consistency with the rest of the platform will get us at  
> least as
> much of a win for authors as would be gotten from uppercase letters.

Would it not make more sense to fix the UAs.
lower-case hex is horrible to read.


- Nicholas.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2157 bytes
Desc: not available
URL: <http://lists.whatwg.org/pipermail/whatwg-whatwg.org/attachments/20070510/f169d741/attachment.bin>
Received on Thursday, 10 May 2007 00:02:52 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:58:55 UTC