本文整理汇总了Java中lecho.lib.hellocharts.provider.PieChartDataProvider类的典型用法代码示例。如果您正苦于以下问题:Java PieChartDataProvider类的具体用法?Java PieChartDataProvider怎么用?Java PieChartDataProvider使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
PieChartDataProvider类属于lecho.lib.hellocharts.provider包,在下文中一共展示了PieChartDataProvider类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: PieChartRenderer
import lecho.lib.hellocharts.provider.PieChartDataProvider; //导入依赖的package包/类
public PieChartRenderer(Context context, Chart chart, PieChartDataProvider dataProvider) {
super(context, chart);
this.dataProvider = dataProvider;
this.touchAdditional = ChartUtils.dp2px(this.density, 8);
this.slicePaint.setAntiAlias(true);
this.slicePaint.setStyle(Style.FILL);
this.centerCirclePaint.setAntiAlias(true);
this.centerCirclePaint.setStyle(Style.FILL);
this.centerCirclePaint.setXfermode(new PorterDuffXfermode(Mode.SRC));
this.centerCircleText1Paint.setAntiAlias(true);
this.centerCircleText1Paint.setTextAlign(Align.CENTER);
this.centerCircleText2Paint.setAntiAlias(true);
this.centerCircleText2Paint.setTextAlign(Align.CENTER);
this.separationLinesPaint.setAntiAlias(true);
this.separationLinesPaint.setStyle(Style.STROKE);
this.separationLinesPaint.setStrokeCap(Cap.ROUND);
this.separationLinesPaint.setXfermode(new PorterDuffXfermode(Mode.CLEAR));
this.separationLinesPaint.setColor(0);
}
示例2: PieChartRenderer
import lecho.lib.hellocharts.provider.PieChartDataProvider; //导入依赖的package包/类
public PieChartRenderer(Context context, Chart chart, PieChartDataProvider dataProvider) {
super(context, chart);
this.dataProvider = dataProvider;
touchAdditional = ChartUtils.dp2px(density, DEFAULT_TOUCH_ADDITIONAL_DP);
slicePaint.setAntiAlias(true);
slicePaint.setStyle(Paint.Style.FILL);
centerCirclePaint.setAntiAlias(true);
centerCirclePaint.setStyle(Paint.Style.FILL);
centerCirclePaint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.SRC));
centerCircleText1Paint.setAntiAlias(true);
centerCircleText1Paint.setTextAlign(Align.CENTER);
centerCircleText2Paint.setAntiAlias(true);
centerCircleText2Paint.setTextAlign(Align.CENTER);
separationLinesPaint.setAntiAlias(true);
separationLinesPaint.setStyle(Paint.Style.STROKE);
separationLinesPaint.setStrokeCap(Paint.Cap.ROUND);
separationLinesPaint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.CLEAR));
separationLinesPaint.setColor(Color.TRANSPARENT);
}