Re: [css4-color] #RGBA

  On 2010-09-09 10:16 PM, Tab Atkins Jr. wrote:
>  If you're using an all-gray palette, I don't think it's very taxing
>  to say hsl(0,0%,<gray%>). Not as terse as possible, but pretty
>  good.

It's not really a big deal when you're doing it once. When you have a 
bunch of color rules, it starts getting messy as well as annoying to 
type though. And I can't eliminate the spaces without violating personal 
convention; I try to maintain a consistent coding style.

This isn't an absolute must-have, of course, but since there's already 
brainstorming for CSS4 Color...

>  If we were to specifically address the use-case of "make creating
>  gray colors as terse as possible", I'd just create a gray() function
>  that took a percentage. That's much clearer than some
>  single-argument version of rgb() or hsl().

As far as clarity goes, I think that's a better idea. Given the CSS3 
Color convention of allowing both use of "gray" and "grey" in keywords 
though, you'd also need |grey()| for consistency.

Received on Friday, 10 September 2010 04:22:26 UTC