- From: Tab Atkins Jr. <jackalmage@gmail.com>
- Date: Mon, 17 Feb 2014 07:50:34 -0800
- To: Xidorn Quan <quanxunzhen@gmail.com>
- Cc: www-style list <www-style@w3.org>
On Sun, Feb 16, 2014 at 9:03 PM, Xidorn Quan <quanxunzhen@gmail.com> wrote: > It is mentioned in the spec that not all systems are negative-capable, > or in particular, 'cyclic', 'fixed', and some 'override' are excluded > from negative-capables. I propose that the same rule should be applied > to 'pad' descriptor as well. > > It is obvious that, any 'cyclic' and 'fixed' has only one symbol in > its content according to the definition, as a result, any pad width > larger than 1 only produces a constant prefix for pad part, hence it > is useless since if anyone wants such effect, he could append the pad > symbols to the prefix directly. > > In addition, 'pad' for counter styles in such systems could generate a > counterintuitive result. For example, if someone add 'pad' to the > predefined style 'decimal-leading-zero' which uses 'fixed' system, > assuming pad is "3 '0'", what he expects might be -099, -009, ..., > 009, 099, but what he actually gets will be -99, 00-09, ..., 0009, 99, > which is strange and unacceptable. > > In conclusion, I think 'pad' should not be applied for systems which > is not negative-capable. While it may not be useful in all cases, and can always be approximated manually for cyclic and fixed styles, I don't see anything particularly *wrong* with allowing 'pad' to work with all styles. I prefer not to add restrictions just because some combination doesn't seem useful; as long as it logically works and there aren't further negative implications, like performance, allowing all parts of the language to work together produces a simpler language overall. On the subject of decimal-leading-zero, I should actually just rewrite that as as decimal override with "pad: 2 '0';". That option wasn't available before! ~TJ
Received on Monday, 17 February 2014 15:51:24 UTC