- From: Tab Atkins Jr. via GitHub <sysbot+gh@w3.org>
- Date: Mon, 10 Jan 2022 18:45:56 +0000
- To: public-css-archive@w3.org
As an example of the "usefulness depends on argument ordering", look at the grayscaling example in the spec - one variant is specified as `lch(from var(--color) l 0 h)`, which one could shorten to `lch(from var(--color) l 0)`, dropping the `h`, but the also-superfluous `l` has to remain just because it precedes the chroma argument that is actually changing. Whether a component is dropped or not thus carries no semantic meaning (or at least has its meaning tangled up in irrelevant details), unlike dropping *all* the components. Also, people read non-linearly, and use visual cues both ahead and behind their current attention point to aid in scanning. In this syntax, the first thing after the `from <color>` is always the first component, and the last thing before the `)` is always either the alpha (if `/` is used) or the last component. If one sees `0)` at the end of an lch, one can immediately infer that it's a red. This is broken if one can omit the hue, as in this example where the `0)` instead signals that it's a grayscale color, and the hue is omitted. All these are minor issues that can easily get swept under the rug if the functionality is worthwhile, but here the only benefit is being able to skip the two characters `[space]h` sometimes. -- GitHub Notification of comment by tabatkins Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6938#issuecomment-1009237581 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Monday, 10 January 2022 18:45:58 UTC