Le 2006-03-28 à 16:07, Ian Hickson a écrit :
<meter value="0.25">400k / 16,000k</meter>
...will show a 25% meter, and this:
<meter>400k / 16,000k</meter>
...will show a 2.5% meter.
Assuming you meant 2.5%, I think that's a great example of why in
requiring the attribute is a good thing.
The attribute may be of a standardized format, but the content ought
to be localizable, shouldn't it?
If so, number formats varies around the world, how should these be
<meter>12.20 / 3,000.00</meter>
<meter>12,20 / 3 000,00</meter>
<meter>12,20 / 3.000,00</meter>
I don't think it is possible to extract localized numbers reliably
without knowing the locale first, and you may not want the browser
trying to be that *clever* either.
See <http://en.wikipedia.org/wiki/Decimal_separator> for some more
All this means that if someone relies on setting the content in a web
application to set the value and maximum, when later the application
is internationalized the meter will misbehave until you add the
attribute. It will misbehave but only when having thousand separators
or decimal values -- any such error may be left unnoticed easily.