Skip to content

Instantly share code, notes, and snippets.

@seivan
Created July 16, 2014 01:46
Show Gist options
  • Star 4 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save seivan/d360aaec9780692e3520 to your computer and use it in GitHub Desktop.
Save seivan/d360aaec9780692e3520 to your computer and use it in GitHub Desktop.
NSBezierPath ArcCenter does not work like the UIBezierPath ArcCenter
//This doesn't work as its iOS counterpart
self.appendBezierPathWithArcWithCenter(center, radius: radius, startAngle: startAngle, endAngle: endAngle, clockwise: clockwise)
//This worked like the iOS counterpart
let path = CGPathCreateMutableCopy(self.CGPath)
CGPathAddArc(path, nil, center.x, center.y, radius, startAngle, endAngle, clockwise)
self.CGPath = path
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment