[whatwg] <progress> draft
Michel Fortin
michel.fortin at michelf.com
Tue Mar 28 15:32:11 PST 2006
Le 2006-03-28 à 16:07, Ian Hickson a écrit :
> Currently, this:
>
> <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
> fact not
> 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
handled?
<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
formats.
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.
Michel Fortin
michel.fortin at michelf.com
http://www.michelf.com/
More information about the whatwg
mailing list