Hi,
For Stack Chart, X-Axis gets too crowded. As I have more labels on X-Axis it gets crowded. (i.e., labels overlap with one over other). Is there any other option to avoid this ?
Thanks and Regards,
sakaray_c
X-Axis gets too crowded as there are more labels on X-Axis
-
- JFreeChart Project Leader
- Posts: 11734
- Joined: Fri Mar 14, 2003 10:29 am
- antibot: No, of course not.
- Contact:
Can you post a sample of your chart?
David Gilbert
JFreeChart Project Leader
Read my blog
Support JFree via the Github sponsorship program
JFreeChart Project Leader


X-Axis gets too crowded as there are more labels on X-Axis
Hi,
I am not able to post an image.
I am giving detail information abt my problem.
In Stack Chart X-Axis Labels are very lengthy (like United States Of America, United Kingdom etc). So the labels overlap one over the other.
Is there a way to set these labels with some orientation i.e, can we set the labels with some slope (with some angle) so that the labels doesn't overlap.
Thanks and Regards,
sakaray_c
I am not able to post an image.
I am giving detail information abt my problem.
In Stack Chart X-Axis Labels are very lengthy (like United States Of America, United Kingdom etc). So the labels overlap one over the other.
Is there a way to set these labels with some orientation i.e, can we set the labels with some slope (with some angle) so that the labels doesn't overlap.
Thanks and Regards,
sakaray_c
-
- JFreeChart Project Leader
- Posts: 11734
- Joined: Fri Mar 14, 2003 10:29 am
- antibot: No, of course not.
- Contact:
If you are using 0.9.16, you can try this:
Code: Select all
CategoryAxis domainAxis = plot.getDomainAxis();
domainAxis.setCategoryLabelPositions(CategoryLabelPositions.UP_45);
David Gilbert
JFreeChart Project Leader
Read my blog
Support JFree via the Github sponsorship program
JFreeChart Project Leader


-
- Posts: 22
- Joined: Thu Jan 29, 2004 8:28 pm
X-Axis gets too crowded ...
I got the same problem of "X-Axis gets too crowded" with a different flavor: My chart has hundreds of x-values, and though I set them with "Axis.setCategoryLabelPositions(CategoryLabelPositions.DOWN_90)", hundreds of category labels become a single long contingous black box.
I've scouted many posts concerning this issue, no luck
Ideally, we want to specify that category labels (text) to appear every configurable number of x-values, i.e. says one label at each ten values.
Some solutions must be out there?
I've scouted many posts concerning this issue, no luck

Ideally, we want to specify that category labels (text) to appear every configurable number of x-values, i.e. says one label at each ten values.
Some solutions must be out there?