Package br.com.digilabs.jqplot.chart

Source Code of br.com.digilabs.jqplot.chart.DonutChart

/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package br.com.digilabs.jqplot.chart;

import br.com.digilabs.jqplot.JqPlotResources;
import br.com.digilabs.jqplot.chart.data.ChartData;
import br.com.digilabs.jqplot.chart.elements.Legend;
import br.com.digilabs.jqplot.chart.elements.RendererOptions;
import br.com.digilabs.jqplot.chart.elements.SeriesDefaults;
import br.com.digilabs.jqplot.metadata.JqPlotPlugin;

/**
*
* @author bernardo.moura
*/
@JqPlotPlugin(values = {JqPlotResources.DonutRenderer})
public class DonutChart<T extends ChartData<?>> extends DefaultChart<T> {

    public DonutChart() {
        getChartConfiguration().setLegend(new Legend(true, "e"));
        getChartConfiguration().setSeriesDefaults(new SeriesDefaults());
        getChartConfiguration().getSeriesDefaults().setRenderer(JqPlotResources.DonutRenderer);
        getChartConfiguration().getSeriesDefaults().setRendererOptions(new RendererOptions());
        getChartConfiguration().getSeriesDefaults().getRendererOptions().setSliceMargin(4);
        getChartConfiguration().getSeriesDefaults().getRendererOptions().setDataLabels("value");
        getChartConfiguration().getSeriesDefaults().getRendererOptions().setShowDataLabels(true);
    }
}
TOP

Related Classes of br.com.digilabs.jqplot.chart.DonutChart

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.