Closed GoogleCodeExporter closed 8 years ago
Forgot to mention I am using the latest version of gwt-charts 0.9.9
Original comment by gurvinde...@gmail.com
on 10 Jan 2013 at 8:46
I've tried with this snippet and worked:
GeoChartOptions options = GeoChartOptions.create();
GeoChartColorAxis geoChartColorAxis = GeoChartColorAxis.create();
JsArrayString arrayString = JsArrayString.createArray().cast();
arrayString.set(0, "red");
arrayString.set(1, "blue");
arrayString.set(2, "green");
geoChartColorAxis.setColors(arrayString);
options.setColorAxis(geoChartColorAxis);
Nevertheless, I'll be changing this method so you can simply write:
GeoChartOptions options = GeoChartOptions.create();
GeoChartColorAxis geoChartColorAxis = GeoChartColorAxis.create();
geoChartColorAxis.setColors("red", "blue", "green");
options.setColorAxis(geoChartColorAxis);
Meanwhile can you post a snippet so I can reproduce the problem?
Original comment by rglafo...@gmail.com
on 10 Jan 2013 at 11:22
I have been able to change the colors also with the stand alone project when
used only gwt and gwt-charts latest version. But in the main projects I am
using smartgwt with highcharts, so to me it seems there is some conflict with
name/namespace which is causing the error. The code snippet to reproduce is the
same exactly like this but in the project there are widgets from smartgwt and
highcharts too. If you run the below code in a seperate project it will work
fine but combined with the above mention tools you will get the error reported
earlier by me.
GeoChartOptions options = GeoChartOptions.create();
GeoChartColorAxis colorsAxis = GeoChartColorAxis.create();
colorsAxis.setValues(ArrayHelper.toJsArrayNumber(1,40,100,400,4000));
colorsAxis.setColors(ArrayHelper.toJsArrayString("#FFE6E6","#FF4D4D","#FF0000","#CC0000","#4C0000"));
//colorsAxis.setMinValue(5);
options.setColorAxis(colorsAxis);
options.setRegion("world");
//options.setWidth("100%");
options.setHeight(860);
DataTable dataTable = DataTable.create();
dataTable.addColumn(ColumnType.STRING, "Country");
dataTable.addColumn(ColumnType.NUMBER, "No. od Calls");
dataTable.addRows(4);
dataTable.setValue(0, 0, "India");
dataTable.setValue(1, 0, "US");
dataTable.setValue(2, 0, "UK");
dataTable.setValue(3, 0, "Norway");
dataTable.setValue(0, 1, 5);
dataTable.setValue(1, 1, 75);
dataTable.setValue(2, 1, 3);
dataTable.setValue(3, 1, 2234);
geoChart.draw(dataTable,options);
Thanks for any help/suggestions.
Original comment by gurvinde...@gmail.com
on 11 Jan 2013 at 1:37
[deleted comment]
Probably related to Issue #40
There was an overlapping namespace with the custom ajaxloader.
Original comment by rglafo...@gmail.com
on 27 Aug 2014 at 2:35
Original comment by rglafo...@gmail.com
on 3 Sep 2014 at 11:07
Original issue reported on code.google.com by
gurvinde...@gmail.com
on 10 Jan 2013 at 8:44