【发布时间】:2014-10-23 18:35:04
【问题描述】:
如何创建一个扩大加班的圈子。我想做这样的事情:
[UIView animateWithDuration:5 animations:^(void){
/* Expand the circle */
// Get the contextRef
CGContextRef contextRef = UIGraphicsGetCurrentContext();
// Set the border width
CGContextSetLineWidth(contextRef, 1.0);
// Set the circle fill color to Transparent
CGContextSetRGBFillColor(contextRef, 0.0, 0.0, 0.0, 0.0);
// Set the cicle border color to BLUE
CGContextSetRGBStrokeColor(contextRef, 0.0, 0.0, 255.0, 1.0);
// Fill the circle with the fill color
CGContextFillEllipseInRect(contextRef, self.view.frame);
// Draw the circle border
CGContextStrokeEllipseInRect(contextRef, self.view.frame);
}];
【问题讨论】:
-
动画框架的大小很简单,请参阅许多示例,例如stackoverflow.com/a/6728458/294884
-
“真正做到这一点”的方法是使用惊人的..paintcodeapp.com
标签: ios objective-c