HelloChart--ComboLineColumnChartView(组合统计图)
来源:互联网 发布:娃哈哈的营销网络 编辑:程序博客网 时间:2024/06/04 12:41
在XML中的定义:
<lecho.lib.hellocharts.view. ComboLineColumnChartView android:id="@+id/combochart" android:layout_width="wrap_content" android:layout_height="wrap_content" > </lecho.lib.hellocharts.view. ComboLineColumnChartView >
控件实例化:
ComboLineColumnChartView comboChart;comboChart=(ComboLineColumnChartView)findViewById(R.id.combochart);
chart属性设置:
comboChart.setZoomEnabled(boolean isZoomEnabled)//设置是否支持缩放comboChart.setOnValueTouchListener(ColumnChartOnValueSelectListener touchListener);//为图表设置值得触摸事件comboChart.setInteractive(boolean isInteractive);//设置图表是否可以与用户互动comboChart.setValueSelectionEnabled(boolean idValueSelectionEnabled);//设置图表数据是否选中进行显示comboChart.setComboLineColumnChartData(ComboLineColumnChartData data);//为图表设置数据,数据类型为ComboLineColumnChartData
设置ComboLineColumnChartData 属性及为chart设置数据:
ComboLineColumnChartData comboLineColumnChartData=new ComboLineColumnChartData();//定义组合数据对象 comboLineColumnChartData.setLineChartData(LineChartData lineChartData);//为组合图设置折线图数据 comboLineColumnChartData.setColumnChartData(ColumnChartData columnChartData);//为组合图设置柱形图数据 comboLineColumnChartData.setValueLabelsTextColor(Color.BLACK);// 设置数据文字颜色 comboLineColumnChartData.setValueLabelTextSize(15);// 设置数据文字大小 comboLineColumnChartData.setValueLabelTypeface(Typeface.MONOSPACE);// 设置数据文字样式 comboLineColumnChartData.setAxisYLeft(axisY);// 将Y轴属性设置到左边 comboLineColumnChartData.setAxisXBottom(axisX);// 将X轴属性设置到底部 comboLineColumnChartData.setAxisYRight(axisYRight);//设置右边显示的轴 comboLineColumnChartData.setAxisXTop(axisXTop);//设置顶部显示的轴 comboChart.setComboLineColumnChartData(ComboLineColumnChartData data);//为足额和图添加数据
组合图ComboLineColumnChartData其中添加的数据为LineChartData和ColumnChartData,与LinChartView、CoulmnChartView添加的数据类型一致。
0 0
- HelloChart--ComboLineColumnChartView(组合统计图)
- HelloChart--ComboLineColumnChartView(组合统计图)
- HelloChart--PreviewChartView(预览统计图)
- HelloChart--PreviewChartView(预览统计图)
- HelloChart--ColumnChartView(柱形图)
- HelloChart--PieChartView(饼图)
- HelloChart--ColumnChartView(柱形图)
- HelloChart--PieChartView(饼图)
- AChartEngine高级应用之CombinedXYChart(组合统计图)在单个统计图上显示多样化的数据
- AChartEngine高级应用之CombinedXYChart(组合统计图)在单个统计图上显示多样化的数据
- AChartEngine高级应用之CombinedXYChart(组合统计图)在单个统计图上显示多样化的数据
- HelloChart--LineChartView(折线图)
- HelloChart--BubbleChartView(气泡图)
- HelloChart--BubbleChartView(气泡图)
- HelloChart--LineChartView(折线图)
- hellochart详细讲解(一)折线图
- hellochart详细讲解(二)饼状图
- hellochart详细讲解(三)柱状图
- HelloChart--BubbleChartView(气泡图)
- 高斯金字塔
- LeetCode *** 103. Binary Tree Zigzag Level Order Traversal
- 66、Integer.valueof(String)
- HTML5[5]:在移动端禁用长按选中文本功能
- HelloChart--ComboLineColumnChartView(组合统计图)
- MATLAB区域标记提取指定编号区域
- Android ScrollView里嵌套listview,listview显示不全的问题
- Eclipse的debug调试技巧
- lua 函数库汇总
- 南京理工大学第八届程序设计大赛count_prime
- 卷积神经网络-图像卷积的概念
- Python virtualenv安装库报错SSL: CERTIFICATE_VERIFY_FAILED
- POJ2115 C Looooops(拓展欧几里德)