Link to home
Start Free TrialLog in
Avatar of dshrenik
dshrenikFlag for United States of America

asked on

JFreeChart: Customize X axis labels for a LineChart

I want to customize the labels of a LineChart in the sense that, regardless of the values that I am plotting, I want specific labels on the X-axis.

If possible, please provide some sample code. Thanks!
Avatar of for_yan
for_yan
Flag of United States of America image


I am not sure waht you mean exactly, but look here about custom label generator:

Did you try custom lablel generator, like in the examples below:


http://www.java2s.com/Code/Java/Chart/JFreeChartBarChartDemo7withacustomitemlabelgenerator.htm

http://sources68.com/jfreechart-pie-chart-3d-demo-4-with-a-custom-label-generator-a748442.html

It allows to chacnge many things about the lable - I didn't see font size change, though, but maybe these will behave differently
ASKER CERTIFIED SOLUTION
Avatar of for_yan
for_yan
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial