NumberFormat has not worked the way I expected
(see
https://groups.google.com/d/msg/google-web-toolkit/zlbRIhTKqrA/cyjaDB12K6UJ
for an experience with devmode vs production).
On Monday, April 15, 2013 3:29:30 PM UTC-4, Patrick Tucker wrote:
>
> Today I noticed that the output of my NumberFormat (GWT 2.5.0) is not what
> I thought it had been set to. So I played with it a little and found the
> output to be inconsistent.
>
> The formats:
>
> 1: NumberFormat.getFormat("#,###.##")
> 2: NumberFormat.getFormat("#,###.00")
> 3: NumberFormat.getFormat("#,##0.00")
>
>
> The output is as follows:
>
> 1: 3.57, 0.98, 0.6
> 2: 3.57, .98, .60
> 3: 3.57, 0.98, 0.60
>
> The NumberFormat class doc states the following:
>
> 0 Number Yes Digit
> # Number Yes Digit, zero shows as absent
>
> According to the doc comments, show above, I was expect the following
> output for each format:
>
> 1: 3.57, .98, .6
> 2: 3.57, .98, .60
> 3: 3.57, 0.98, 0.60
>
>
> What going on here? The output for 1 should not have the leading 0, just
> like the 2nd format.
>
> Thanks,
> Pat
>
--
You received this message because you are subscribed to the Google Groups
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.