Rencia
Rencia

Reputation: 71

How to set language on highcharts.client.Chart

HOW does one set the language on org.moxieapps.gwt.highcharts.client.Chart setting the Highcharts.options (in Java) as:

Highcharts.Options options = new Highcharts.Options();
options.setGlobal(new Global().setUseUTC(false));
String[] cat = new String[] {"Jan.", "Fev.", "Março", "Abril", "Maio", "Junho", "Julho", "Agosto", "Set.", "Out.", "Nov.", "Dez."} ;
options.setLang(new Lang().setMonths(cat));
Highcharts.setOptions(options);

has NO effect. Remains in English.

trying to set:

chart.getXAxis()
.setCategories("Jan.", "Fev.", "Março", "Abril", "Maio", "Junho", "Julho", "Agosto", "Set.", "Out.", "Nov.", "Dez.");

fails: --> Chromium fails: V8 error: Allocation failed - process out of memory (invalid array length). Current memory usage: 890 MB

--> Firefox complains of a script error

Fails even using documented example of:

chart.getXAxis().setCategories(....)

HELP please!

Upvotes: 1

Views: 520

Answers (1)

Rencia
Rencia

Reputation: 71

Lol! I needed to

options.setLang(new Lang().setShortMonths(cat));

!!!

Upvotes: 2

Related Questions