Hi Alvaro, You can automatically have the GeoChart use the right locale by specifying the 'language' parameter to google.load. Here is an example of that: http://jsfiddle.net/brw4gj21/
Alternatively, you could specify a pattern like '#,##', which would effectively replace the decimal separator. I think the ICU format is flexible enough to do what you want. On Thu, May 21, 2015 at 6:18 AM Alvaro Fernández Seco < [email protected]> wrote: > Hello, > > I have a geoChart embedded in a web page where number formatting is taking > into account the current locale. > > I want to use a different decimal separator simbol in geoChart legend, for > instance: > > locale > legend > es 25,89 [gradient rect legend] 68,78 > en 25.89 [gradient rect legend] 68.78 > > I've been trying to achieve this using *legend.numberFormat* on geoChart > options, but it expects a string... and there is no way to set decimal > symbol. > > I was hoping to use there something like a > *google.visualization.NumberFormat*({decimalSymbol: ','}) object but it > doesn't work. > > I am able to achive this behaviour listening for ready event on geoChart > and updating all svg > text tags using something like > $('#your-geo-chart-div svg text').text().replace('.', ','). > > But whenever a click/mouseover event is fired over the geoChart it seems > that the full legend is destroyed and re-recreated again... so it only > works for first rendering. > > Did anyone encountered this problem before? Any tips or ideas on how to > get this working will be highly appreciated. > > Regards, > Alvaro. > > > -- > You received this message because you are subscribed to the Google Groups > "Google Visualization API" 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-visualization-api. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Google Visualization API" 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-visualization-api. For more options, visit https://groups.google.com/d/optout.
