本文整理汇总了Java中org.jfree.chart.renderer.category.BarRenderer.setItemLabelPaint方法的典型用法代码示例。如果您正苦于以下问题:Java BarRenderer.setItemLabelPaint方法的具体用法?Java BarRenderer.setItemLabelPaint怎么用?Java BarRenderer.setItemLabelPaint使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.jfree.chart.renderer.category.BarRenderer
的用法示例。
在下文中一共展示了BarRenderer.setItemLabelPaint方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: testSetItemLabelPaint
import org.jfree.chart.renderer.category.BarRenderer; //导入方法依赖的package包/类
/**
* Test that setting the paint for ALL series does in fact work (it was
* broken at one point).
*/
@Test
public void testSetItemLabelPaint() {
BarRenderer r = new BarRenderer();
r.setItemLabelPaint(Color.green);
assertEquals(Color.green, r.getItemLabelPaint(0, 0));
}
示例2: setItemLabels
import org.jfree.chart.renderer.category.BarRenderer; //导入方法依赖的package包/类
/**
* not in use yet. This method generates labels above each bar. At this very moment, these labels just show the value of the underlying data
* (which is not very usefull). It could be used to display for example n-values.
* @param plot
*/
@SuppressWarnings("unused")
private void setItemLabels(final CategoryPlot plot) {
final BarRenderer renderer = (BarRenderer) plot.getRenderer();
renderer.setItemLabelGenerator(new StandardCategoryItemLabelGenerator()); // TODO change to a custom ItemLabelGenerator; see JFreeChart
// developer Guide, version 0.9.18 (april 2004), page 80 and
// following pages
renderer.setItemLabelsVisible(true);
renderer.setItemLabelFont(new Font("SansSerif", Font.PLAIN, 9));
renderer.setItemLabelPaint(null);
renderer.setSeriesItemLabelPaint(0, renderer.getSeriesPaint(0));
renderer.setSeriesItemLabelPaint(1, renderer.getSeriesPaint(1));
}
示例3: testSetItemLabelPaint
import org.jfree.chart.renderer.category.BarRenderer; //导入方法依赖的package包/类
/**
* Test that setting the paint for ALL series does in fact work (it was broken at
* one point).
*/
public void testSetItemLabelPaint() {
BarRenderer r = new BarRenderer();
r.setItemLabelPaint(Color.green);
assertEquals(Color.green, r.getItemLabelPaint(0, 0));
}
示例4: testSetItemLabelPaint
import org.jfree.chart.renderer.category.BarRenderer; //导入方法依赖的package包/类
/**
* Test that setting the paint for ALL series does in fact work (it was
* broken at one point).
*/
public void testSetItemLabelPaint() {
BarRenderer r = new BarRenderer();
r.setItemLabelPaint(Color.green);
assertEquals(Color.green, r.getItemLabelPaint(0, 0));
}