Example usage for com.google.gwt.visualization.client.formatters ColorFormat create

List of usage examples for com.google.gwt.visualization.client.formatters ColorFormat create

Introduction

In this page you can find the example usage for com.google.gwt.visualization.client.formatters ColorFormat create.

Prototype

public static native ColorFormat create() ;

Source Link

Usage

From source file:edu.cudenver.bios.glimmpse.client.panels.guided.EffectSizeBarChart.java

License:Open Source License

private AbstractDataTable createTable() {
    //DataTable data = DataTable.create();
    data.addColumn(ColumnType.STRING, "Label");
    data.addColumn(ColumnType.NUMBER, "Difference");
    data.addRows(4);/*from   ww w  .j  a  v a  2  s  .co m*/
    data.setValue(0, 0, "M,Aggggggggggggggggggggggggggggggggg");
    data.setValue(0, 1, 1);
    data.setValue(1, 0, "M,B");
    data.setValue(1, 1, 2);
    data.setValue(2, 0, "F,A");
    data.setValue(2, 1, 2);
    data.setValue(3, 0, "F,B");
    data.setValue(3, 1, 1);

    ColorFormat format = ColorFormat.create();
    format.addRange(-1, 2000, "white", "yellow");
    format.format(data, 1);

    return data;
}