All chart values do not show in line graph in achartengine

夙愿已清 提交于 2019-12-24 16:07:40

问题


Iam creating a line graph with 2 lines. Everything is displayed properly except when i use renderer.setDisplayChartValues(true) the values are plotted but not all titles of the values are displayed.

Can anybody help me with this? Thank you

Here is the code

renderer1 = new XYSeriesRenderer();
        renderer1.setDisplayChartValues(true);
        renderer1.setColor(Color.parseColor("#FFDC143C"));
        renderer1.setPointStyle(PointStyle.CIRCLE);
        renderer1.setFillPoints(true);
        rRenderer.addSeriesRenderer(renderer1);

        renderer2= new XYSeriesRenderer();
        renderer2.setDisplayChartValues(true);
        renderer2.setPointStyle(PointStyle.CIRCLE);
         renderer2.setColor(Color.parseColor("#FF6B8E23"));
        renderer2.setFillPoints(true);
        rRenderer.addSeriesRenderer(renderer2);

回答1:


You can change the minimum distance between chart values in order to get more of them displayed. For instance:

renderer.setDisplayChartValuesDistance(10);


来源:https://stackoverflow.com/questions/18032462/all-chart-values-do-not-show-in-line-graph-in-achartengine

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!