java - How to show ColumnKey on bar in JFreeChart? -
i have stacked bar chart in image above. need show column keys ("series 1","series 2","series 3") on bars instead of values. how can that?
you can this:
renderer.setbaseitemlabelgenerator( new standardcategoryitemlabelgenerator("{0}", numberformat.getinstance()));
the label generator works off template replaces instances of '{0}' series name, '{1}' category key, , '{2}' data value. number formatter passed constructor used formatting data values (but in case, data value not displayed formatter not used).
Comments
Post a Comment