标签:style blog http io ar color os 使用 sp
KYCircularProgress
Flexible progress bar written in Swift.
用Swift语言编写的灵活的进度条控件。
Create KYCircularProgress 创建KYCircularProgress
var circularProgress: KYCircularProgress! = KYCircularProgress(frame: self.view.bounds)
// support Hex color to RGB color
circularProgress.colors = [0xA6E39D, 0xAEC1E3, 0xE1A5CB, 0xF3C0AB]
circularProgress.progressChangedClosure({ (progress: Double, circularView: KYCircularProgress) in
println("progress: \(progress)")
})
UIBezierPath Progress Bar 贝塞尔曲线的bar
// create "Star progress bar"
let path = UIBezierPath()
path.moveToPoint(CGPointMake(50.0, 2.0))
path.addLineToPoint(CGPointMake(84.0, 86.0))
path.addLineToPoint(CGPointMake(6.0, 33.0))
path.addLineToPoint(CGPointMake(96.0, 33.0))
path.addLineToPoint(CGPointMake(17.0, 86.0))
path.closePath()
circularProgress.path = path
KYCircularProgress.swift
in your project. 将KYCircularProgress.swift添加到你的项目当中即可
标签:style blog http io ar color os 使用 sp
原文地址:http://www.cnblogs.com/YouXianMing/p/4138901.html