Re: Issue regarding NumberFormat

2014-12-29 Thread Ignacio Baca Moreno-Torres
4 10:24:34 AM UTC+1, Gaurav Mourya wrote: > > Hi All, > > I am using GWT 2.5.1 and I have an issue regarding “NumberFormat” supports > for multiple language. > > Please refer the following below URL : - > http://samples.gwtproject.org/samples/Showcase/Showcase.html?local

Issue regarding NumberFormat

2014-12-29 Thread Gaurav Mourya
Hi All, I am using GWT 2.5.1 and I have an issue regarding “NumberFormat” supports for multiple language. Please refer the following below URL : - http://samples.gwtproject.org/samples/Showcase/Showcase.html?locale=en_GB#!CwNumberFormat As per required pattern I’ll be not getting value

NumberFormat

2013-05-20 Thread Muhammed Abdul Salim
Hai, I have a doubt regarding currency format in GWT.I am using gwt2.5 and tried formatting my value to Indian currency format using "il8n NumberFormat" by setting "Locale = en_IN" in gwt.xml. when i execute my code result was Rs. 10,000,000.00 instead of Rs 10,00,00,00

Re: NumberFormat output wrong?

2013-04-22 Thread Philippe Lhoste
On 16/04/2013 18:43, Thad wrote: 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

Re: NumberFormat output wrong?

2013-04-16 Thread Thad
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

NumberFormat output wrong?

2013-04-15 Thread Patrick Tucker
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: Nu

NumberFormat and Internationalization Messages

2012-11-22 Thread Thad
I'm am unable to get com.google.gwt.i18n.client.Messages for format a float in production. My DefaultMessage looks like "{0,float,#.0}\"". In DevMode, my number has one digit after the decimal, e.g., 8.8" or 11.6" In production--now Javascript vs Java--the number has *many* digits after the de

Re: How to use NumberFormat to set maximum number of integer digit

2012-06-30 Thread Bakul
Simply split it by dot. Take last 3 chars of first string, use formatting for second. And join again by dot -Bakul -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To view this discussion on the web visit https://groups.google.com/d/msg/

Re: How to use NumberFormat to set maximum number of integer digit

2012-06-30 Thread Joseph Lust
> > that means format a 1234.567 will get 234.58. > Why would you ever want to do that? Now you users don't know if you are displaying 234 or 1234 of 1000234. Your trouble might be coming from this unusual formatting you are attempting. Most number formatting functions won't do this because i

How to use NumberFormat to set maximum number of integer digit

2012-06-29 Thread Mao Qin
Hi everyone, There is one topic about how-to use NumberFormat to set minimum number of integer digit. But now I come across one problem, I only wanna keep the decimal format looking like "000.00", three integer and two number after decimal point. that means format a 1234.567 will

NumberFormat custom grouping separator

2012-01-02 Thread tanteanni
(Happy New Year!) I need to change grouping separator (, in US . in DE) to Space (' ') for all Locales how to achieve that? thx in advance -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To view this discussion on the web visit https:/

Re: NumberFormat currency pattern issues (wrong positiveSuffix and possible encoding issues)

2011-12-16 Thread Tiago
ng or refusing currency symbols and/or currency codes). What I don't find correct is to always require a " €".. the user can't even type a  ... Not being able to use NumberFormat to parse currency values would be a pity. I would expect to be able to use the same format both way

Re: NumberFormat currency pattern issues (wrong positiveSuffix and possible encoding issues)

2011-12-16 Thread Thomas Broyer
Not sure this is a bug, maybe by-design (i.e. don't use the currency format for parsing). If you want to parse a number, don't use a currency format. If you expect the user to (optionally) type in the currency symbol, you'd better pre-process the value (what if the user types "$10" in a € locale?

Re: NumberFormat currency pattern issues (wrong positiveSuffix and possible encoding issues)

2011-12-15 Thread Tiago
Thank you Thomas for the clarification. Do you agree though that there's a bug on NumberFormat? It should not require " €" to be in the end of a string it parses, although it may add it to the end of a string it formats. Right? On Dec 15, 2:40 pm, Thomas Broyer wrote: &g

Re: NumberFormat currency pattern issues (wrong positiveSuffix and possible encoding issues)

2011-12-15 Thread Thomas Broyer
-62, -96, or in hexadecimal C2,A0 is the encoding (in UTF-8) of a non-breaking space (U+00A0, widely known on the web as  ) It's a distinct Unicode character than a space (U+0020, encoded in UTF-8 as 32); it's not an encoding issue (btw, all strings in JavaScript are in UCS-2, just like in Java

NumberFormat currency pattern issues (wrong positiveSuffix and possible encoding issues)

2011-12-15 Thread Tiago Rinck Caveden
Hello, I'm having some weird issues with NumberFormat. I'm using it with the currency pattern, which for my locale is the euro. The first problem I've notice is that the parser is treating the string " €" as a "positiveSuffix". And if such string is not at the

NumberFormat format with all available decimal digits

2011-08-29 Thread Raziel
Hi, I would like to be able to call the NumberFormat format method with a Double and get in the string all the digits available in the Double value. It seems to me that you have to forcefully specify in the patter one digit per decimal you want to display (i.e. "#.#" for 5 deci

Re: NumberFormat and German Locale

2011-07-12 Thread tdk
ok, thanks everyone who contribute. My conclusion is quite simple: since I only have a localized pattern, I won't be able to use that and format the numbers acc. to it. -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group

Aw: Re: NumberFormat and German Locale

2011-07-12 Thread Jens
uot; are special symbols used by the NumberFormat class for grouping and as decimal separator. You always have to use these symbols like they are defined in the JavaDoc for NumberFormat regardless of the target locale you want to use. The target locale is then responsible for changing ",&q

Re: NumberFormat and German Locale

2011-07-12 Thread tdk
On 12 Jul., 10:26, Thomas Broyer wrote: > You're confusing the syntax of the pattern you give to NumberFormat for > parsing, and then the use of that NumberFormat within the context of a > locale. > What you *give* to NumberFormat is locale-insensitive: #,##0.0## >

Re: NumberFormat and German Locale

2011-07-12 Thread Thomas Broyer
You're confusing the syntax of the pattern you give to NumberFormat for parsing, and then the use of that NumberFormat within the context of a locale. What you *give* to NumberFormat is locale-insensitive: #,##0.0## When you have that NumberFormat instance, what it does then depends o

Re: NumberFormat and German Locale

2011-07-11 Thread tdk
Tom, Rob, thanx for this valuable information. That default is not "default" is quite interesting, I wasn't aware of that. But then the question is, how do I change the NumberFormat so that it uses the set locale, eg de_DE, instead of "default"? I have not been able to fi

Re: NumberFormat and German Locale

2011-07-11 Thread Thomas Broyer
In a pattern, a dot is always the decimal separator and a comma always represents the thousands separator. When you render a number using the pattern, those separators might appear differently depending on the locale (e.g. the decimal separator being a comma and the thousands separator being a

Re: NumberFormat and German Locale

2011-07-11 Thread Rob Coops
used by my app, because > all the default texts, eg when loading data, show up in german. > > The documentation (and posts in various forms) say, that NumberFormat > uses the default locale to get a formatter, with a specific pattern, > which I assume in my case is de_DE, becaus

NumberFormat and German Locale

2011-07-11 Thread tdk
#.##0,0##. I know that the locale is set correctly and used by my app, because all the default texts, eg when loading data, show up in german. The documentation (and posts in various forms) say, that NumberFormat uses the default locale to get a formatter, with a specific pattern, which I assume

NumberFormat not formatting single-digit numbers

2011-04-13 Thread Kyle
Hi! I'm working on an enterprise GWT/GXT application and we've recently noticed that our currency fields are not correctly formatting single- digit inputs. We're using java.math.BigDecimal to represent the internal values, and using NumberFormat.getFormat("$#,##0.00; ($#,##0.00)") for our format

fixed-width numbers with NumberFormat

2010-11-14 Thread decitrig
I know I can pad a number with zeros, is there a way to pad them with blanks? There are a couple of rules in the EBNF that seem to point this way: number := (integer ('.' fraction)?) | sigDigits sigDigits := '#'* '@''@'* '#'* padSpec := '*' padChar padChar := '\u'..'

Re: Currency Symbol in NumberFormat

2010-10-26 Thread Jim Douglas
Click this link: http://gwt.google.com/samples/Showcase/Showcase.html#!CwNumberFormat Look for the ListBox in the top right corner of that page. Select "English - India" from that list. The page changes to: http://gwt.google.com/samples/Showcase/Showcase.html?locale=en_IN#!CwNumberFormat Note

Re: Currency Symbol in NumberFormat

2010-10-26 Thread PARAG
Hi Jim, Thanks for looking into it. But still I have a problem, when in the custom format I use just ¤ then in the output I am getting ? and when I use ¤ then I get US$. Note that I do have UTF-8 encoding in the browser. On Oct 27, 1:23 am, Chris Conroy wrote: > Jim, > > Thanks for pointing out

Re: Currency Symbol in NumberFormat

2010-10-26 Thread Chris Conroy
Jim, Thanks for pointing out this problem. jat has just committed a fix: http://code.google.com/p/google-web-toolkit/source/detail?r=9150 On Tue, Oct 26, 2010 at 3:47 AM, Jim Douglas wrote: > I think you're getting thrown by a small character encoding error on > that documentation page: > > > h

Re: Currency Symbol in NumberFormat

2010-10-26 Thread Jim Douglas
I think you're getting thrown by a small character encoding error on that documentation page: http://google-web-toolkit.googlecode.com/svn/javadoc/2.1/com/google/gwt/i18n/client/NumberFormat.html The page will display correctly if you force it to display in UTF-8. To do that, select something lik

Currency Symbol in NumberFormat

2010-10-25 Thread PARAG
Hi, I want to use custom number format which may contain currency symbol for perticular locale. I found that with the com.google.gwt.i18n.client.NumberFormat class we can achieve this but the symbol for the currency is ¤ instead of ¤ in java. Note that the unicode used is same as that of the java

Re: NumberFormat on integer

2010-08-17 Thread Patrick Tucker
Jul 7, 2010 at 1:36 PM, Patrick Tucker wrote: > > Nobody knows?? > > > On Jun 23, 10:28 am, Patrick Tucker wrote: > > > Why does GWT not have a getIntegerInstance() in NumberFormat?? > > > > It seems simple enough to implement and it is part of java...

Re: NumberFormat on integer

2010-07-07 Thread Isaac Truett
I know that patches are always welcome<http://code.google.com/webtoolkit/makinggwtbetter.html> . On Wed, Jul 7, 2010 at 1:36 PM, Patrick Tucker wrote: > Nobody knows?? > > On Jun 23, 10:28 am, Patrick Tucker wrote: > > Why does GWT not have a getIntegerInstance() in Numb

Re: NumberFormat on integer

2010-07-07 Thread Patrick Tucker
Nobody knows?? On Jun 23, 10:28 am, Patrick Tucker wrote: > Why does GWT not have a getIntegerInstance() in NumberFormat?? > > It seems simple enough to implement and it is part of java... > > Is it implemented somewhere else? > > Thanks, > Pat -- You received this

NumberFormat on integer

2010-06-23 Thread Patrick Tucker
Why does GWT not have a getIntegerInstance() in NumberFormat?? It seems simple enough to implement and it is part of java... Is it implemented somewhere else? Thanks, Pat -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To po

Re: [Javascript Error] NumberFormat

2010-04-02 Thread Gourab Panda
Hi, The below code works for me NumberFormat threeDForm = NumberFormat.getFormat("#.###"); Thanks and Regards Gourab. On Thu, Mar 25, 2010 at 3:02 PM, StrongSteve wrote: > Hello, > > I experience the following - from my point of view unexplainable - > behavi

NumberFormat

2010-04-01 Thread brianw
hi there, I've been trying to format decimals numbers in the French style; eg 5 000,00 tried setting a number pattern, nothing worked; api says "corresponding locale symbol collection" are in com.google.gwt.i18n.client.constants and there one reads: use LocaleInfo.getCurrentLocale().getNumberCons

Re: NumberFormat

2010-04-01 Thread Yegor
- from my point of view unexplainable - > > behaviour when using the GWT NumberFormat > > (com.google.gwt.i18n.client.NumberFormat). I am using GWT 2.0.3, > > Eclipse Ganymed and IE8/FF3.6. > > > Within my client package I have a static helper class which contains > > the fol

Re: NumberFormat

2010-04-01 Thread StrongSteve
No one? On Mar 25, 11:32 am, StrongSteve wrote: > Hello, > > I experience the following - from my point of view unexplainable - > behaviour when using the GWT NumberFormat > (com.google.gwt.i18n.client.NumberFormat). I am using GWT 2.0.3, > Eclipse Ganymed and IE8/FF3.6. &g

[Javascript Error] NumberFormat

2010-03-25 Thread StrongSteve
Hello, I experience the following - from my point of view unexplainable - behaviour when using the GWT NumberFormat (com.google.gwt.i18n.client.NumberFormat). I am using GWT 2.0.3, Eclipse Ganymed and IE8/FF3.6. Within my client package I have a static helper class which contains the following

Re: NumberFormat/DateTimeFormat reusability

2010-02-24 Thread cretz
Since you are in JavaScript, thread safety should not matter as far as concurrent updates to object state. Regardless, you can see from the code in both classes that the state is not really changed once the pattern has been parsed. Of course, there can be memory size issues if you store lots objec

NumberFormat/DateTimeFormat reusability

2010-02-23 Thread Evgeny Shepelyuk
Hello, Are classes mentioned in subject thread-safew and reusable. For instance if i'm using them in cell renderer in GXT grid for formatting value. Should i create instance each time i need to format value or instance can be created once and then reused ? -- Best Regards Evgeny K. Shepelt

Are NumberFormat and DateFormat reusable ?

2010-02-23 Thread jk
Hello, I was unable to find any info regarding my questions. Are those 2 classes from com.google.gwt.i18n.client package are reusable ? For example if i'm using grid cell renderer in GXT should i create new instance each time i need to format value or i can create formatter instance once and reuse

Re: NumberFormat problems(8 decimal places)

2010-02-15 Thread tomasm
Hi, This is a known bug. See http://code.google.com/p/google-web-toolkit/issues/detail?id=4368 for more details and workarounds. -Tomas On Feb 5, 4:43 am, Tercio wrote: > Hi! > > I have aNumberFormatwith 8 decimal places, that the code: > >                NumberFormatformat =NumberFormat.getFo

NumberFormat problems(8 decimal places)

2010-02-04 Thread Tercio
Hi! I have a NumberFormat with 8 decimal places, that the code: NumberFormat format = NumberFormat.getFormat("#,##0."); System.out.println(format.format(1234.5678d)); When I run, it prints: "1,234.7852517" But should print: "1,2

NumberFormat not understanding its own output?

2009-12-28 Thread Jaroslav Záruba
I can't get NumberFormat working, it seems like it can't parse its own output. I have copied following from the watch-panel in Eclipse: /* * NumberFormat decimalFormat = * com.google.gwt.i18n.client.NumberFormat.getDecimalFormat(); */ "decimalFormat.format(123

NumberFormat not understanding its own output?

2009-12-22 Thread Jaroslav Záruba
I can't get the NumberFormat working, it seems like it can't parse its own output. I have copied following from the watch-panel in Eclipse: /* * NumberFormat decimalFormat = com.google.gwt.i18n.client.NumberFormat.getDecimalFormat(); */ "decimalFormat.format(123

Re: NumberFormat, change seperator's

2009-11-08 Thread rjcarr
Hi SkiD- Doesn't your subject answer your question? Isn't the NumberFormat class what you're looking for? http://google-web-toolkit.googlecode.com/svn/javadoc/1.6/index.html?com/google/gwt/i18n/client/NumberFormat.html On Nov 6, 8:38 am, SkiD wrote: > Hello, > > i wan

Re: NumberFormat getCurrenyFormat()

2009-03-19 Thread fatjack1...@googlemail.com
was to convert it from a String to > > an integer. I think I have fixed part of the problem. My code now > > looks like this: > > > NumberFormat fmt = NumberFormat.getCurrencyFormat(); > > String formatted = fmt.format(discountAmount); > > discountAmount = Integer

Re: NumberFormat getCurrenyFormat()

2009-03-18 Thread fatjack1...@googlemail.com
Or at least change it to £2.57 instead of $? On Mar 17, 8:58 pm, "fatjack1...@googlemail.com" wrote: > Ok, > > The reason I wasparsing it back in was to convert it from a String to > an integer. I think I have fixed part of the problem. My code now > looks like t

Re: NumberFormat getCurrenyFormat()

2009-03-17 Thread fatjack1...@googlemail.com
Ok, The reason I wasparsing it back in was to convert it from a String to an integer. I think I have fixed part of the problem. My code now looks like this: NumberFormat fmt = NumberFormat.getCurrencyFormat(); String formatted = fmt.format(discountAmount); discountAmount = Integer.parse

Re: NumberFormat getCurrenyFormat()

2009-03-17 Thread MN
e > code I am using: > > //Format the discount to two decimal places > NumberFormat fmt = NumberFormat.getCurrencyFormat(); > String formatted = fmt.format(discountAmount); > discountAmount = NumberFormat.getCurrencyFormat().parse(formatted); > > The discount amount fiel

NumberFormat getCurrenyFormat()

2009-03-17 Thread fatjack1...@googlemail.com
Hi, I am having some problems correctly displaying currency. Here is the code I am using: //Format the discount to two decimal places NumberFormat fmt = NumberFormat.getCurrencyFormat(); String formatted = fmt.format(discountAmount); discountAmount = NumberFormat.getCurrencyFormat().parse

NumberFormat currency format - number of decimal places based on currency code?

2008-10-30 Thread Dobes
I'm trying to format international currency values all in the same application, and I'm switching from using my home-baked solution to using GWT's NumberFormat. What I can't figure out is how to determine and change the number of decimal places for each currency. For examp

Re: Does gwt NumberFormat support COMMA as decimal seperator?

2008-10-21 Thread obesga
IL PROTECTED]> wrote: > Does gwt NumberFormat support COMMA as decimal seperator? (for LOCALE > France etc) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post

Does gwt NumberFormat support COMMA as decimal seperator?

2008-10-20 Thread Kelvin
Does gwt NumberFormat support COMMA as decimal seperator? (for LOCALE France etc) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to Google-W