如何创建一个条形图的Andr​​oid? [英] how to create a bar graph in android?

查看:82
本文介绍了如何创建一个条形图的Andr​​oid?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个要求,以创建水平条形图,显示两个值之间的比较。所以,我只需要创建两个水平吧,第一个是总量,第二个是消费量。

I have a requirement to create a horizontal bar graph that shows comparison between two values. So I need to create only two horizontal bars, first one is for total amount and second one is for consumed amount.

可能有人请帮助我建议创建一个条形图机器人。我期待着听到您在最早的。

could some one please help me with suggestions to create a bar chart in android. I look forward to hearing from you at the earliest.

在此先感谢

推荐答案

刚查这个的 条形图Android中指出,没有任何内置的罐子 。在这里,你可以画图表,没有任何内置的罐子。它只是简单的图表创建使用设置高度为TextView的在ListView的概念。

Just check this Bar Chart in Android With out any Built in jars. Here you can draw charts without any built in jars. Its just simple Graph creation using the concept of setting the height for the textview in a ListView.

我用href="http://www.dev-smart.com/archives/34" rel="nofollow">水平的ListView 的

I implemented this by using the Horizontal ListView. Here you have the two double arrays with equal size of elements. And the graph will adjust according to the orientation(Portrait and landscape).

如果你想在一个活动多的图表,你可以在布局实现另一个水平列表视图。

If you want more charts in one activity, you can implement another Horizontal Listview in the layout.

我希望这会帮助你......

I hope this will help you....

这篇关于如何创建一个条形图的Andr​​oid?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆