use of org.xclcharts.renderer.bar.Bar in project XCL-Charts by xcltapestry.
the class MultiAxisChart01View method renderBar.
/**
* 定制柱形顶上的标签格式
*/
private void renderBar() {
Bar bar = chart.getBar();
bar.setItemLabelVisible(true);
bar.setItemLabelRotateAngle(-90);
bar.getItemLabelPaint().setFakeBoldText(true);
chart.setItemLabelFormatter(new IFormatterDoubleCallBack() {
@Override
public String doubleFormatter(Double value) {
// TODO Auto-generated method stub
// DecimalFormat df=new DecimalFormat("#0.00");
DecimalFormat df = new DecimalFormat("#0");
return df.format(value).toString();
}
});
}
Aggregations