Reputation: 1024
Iam using AChartEngine Stacked Bar Chart. Can i add spacing between X-Axis Title and X-Axis Labels. They are too closed to each other.
set Bottom Margin will only add spacing between X-Axis Title and Legend.
Upvotes: 8
Views: 6464
Reputation: 325
A quick patch which solved my problem, modify your X-Axis Title and prefix it with new lines, e.g
renderer.setXTitle("\n\n\n Months");
Upvotes: 14
Reputation: 32391
Use the setMargins()
method. You can set the margins between the chart and the margins of the screen.
renderer.setMargins(new int[] {30, 100, 10, 0);
The order of the values in the parameter array is: top, left, bottom, right. So, you will need to increase the left value.
Upvotes: 12