use of org.opennms.netmgt.config.charts.ChartBackgroundColor in project opennms by OpenNMS.
the class ChartUtils method setChartBackgroundColor.
private static void setChartBackgroundColor(BarChart chartConfig, JFreeChart chart) {
if (chartConfig.getChartBackgroundColor().isPresent()) {
final ChartBackgroundColor bgColor = chartConfig.getChartBackgroundColor().get();
Red red = bgColor.getRgb().getRed();
Blue blue = bgColor.getRgb().getBlue();
Green green = bgColor.getRgb().getGreen();
chart.setBackgroundPaint(new Color(red.getRgbColor(), green.getRgbColor(), blue.getRgbColor()));
}
}
Aggregations