[翻译] VBPieChart

VBPieChart

https://github.com/sakrist/VBPieChart

Pie Chart iOS control with different animations to present.

Usage - 使用

VBPieChart *chart = [[VBPieChart alloc] init];
[self.view addSubview:chart];
[chart setFrame:CGRectMake(10, 50, 300, 300)];
[chart setEnableStrokeColor:YES];
[chart setHoleRadiusPrecent:0.3]; /* hole inside of chart */
NSArray *chartValues = @[...];
[chart setChartValues:chartValues animation:YES];

Animation options:

动画的种类: 

  • VBPieChartAnimationFanAll
  • VBPieChartAnimationGrowth
  • VBPieChartAnimationGrowthAll
  • VBPieChartAnimationGrowthBack
  • VBPieChartAnimationGrowthBackAll
  • VBPieChartAnimationFan
  • VBPieChartAnimationTimingEaseInOut
  • VBPieChartAnimationTimingEaseIn
  • VBPieChartAnimationTimingEaseOut
  • VBPieChartAnimationTimingLinea

For:
- (void) setChartValues:(NSArray *)chartValues animation:(BOOL)animation duration:(float)duration options:(VBPieChartAnimationOptions)options;

原文地址:https://www.cnblogs.com/YouXianMing/p/4068341.html