How do I set margins / padding for X-axis values in mpadroidchart?

I have graphs and values with graphs on the x-axis overlay

Is there any way to solve it? You may need to add some margins between the x-axis values

resolvent:

It's been a while since you published the problem. Maybe you have found a solution to the problem so far, but I'm publishing this answer to other people who encounter this problem

set up

chart.getXAxis().setSpaceMin(0.5f);

This will add space between the X axis and the chart itself. You can also use

chart.getXAxis().setSpaceMax(0.5f);

Use to add space between the last value of the chart and the right X axis

This is an example of normal chart, and the minimum and maximum space of chart is 1.5

By the way, I'm using mpandroidchart v3.0.2

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>