- [_path moveToPoint:NSMakePoint( 0.0, (vh - 24.0) )]; // first point
- [_path curveToPoint:NSMakePoint( 24.0, vh )
- controlPoint1:NSMakePoint( 0.0, (vh - 11.0) )
- controlPoint2:NSMakePoint( 11.0, vh )]; // top-left curve
- [_path lineToPoint:NSMakePoint( (vw - 24.0), vh )]; // top line
- [_path curveToPoint:NSMakePoint( vw, (vh - 24.0) )
- controlPoint1:NSMakePoint( (vw - 11.0), vh )
- controlPoint2:NSMakePoint( vw, (vh - 11.0) )]; // top-right curve
- [_path lineToPoint:NSMakePoint( vw, 24.0 )]; // right line
- [_path curveToPoint:NSMakePoint( (vw - 24.0), 0.0 )
- controlPoint1:NSMakePoint( vw, 11.0 )
- controlPoint2:NSMakePoint( (vw - 11.0), 0.0 )]; // bottom-right curve
- [_path lineToPoint:NSMakePoint( 24.0, 0.0 )]; // bottom line
- [_path curveToPoint:NSMakePoint( 0.0, 24.0 )
- controlPoint1:NSMakePoint( 11.0, 0.0 )
- controlPoint2:NSMakePoint( 0.0, 11.0 )]; // bottom-left curve
- [_path closePath]; // left line
+ [path moveToPoint:pointA]; // first point
+ [path appendBezierPathWithArcWithCenter:ctrAB // bottom-left curve
+ radius:24.0
+ startAngle:90.0
+ endAngle:180.0];
+ [path lineToPoint:pointC]; // left line
+ [path appendBezierPathWithArcWithCenter:ctrCD // top-left curve
+ radius:24.0
+ startAngle:180.0
+ endAngle:270.0];
+ [path lineToPoint:pointE]; // top line
+ [path appendBezierPathWithArcWithCenter:ctrEF // top-right curve
+ radius:24.0
+ startAngle:270.0
+ endAngle:0.0];
+ [path lineToPoint:pointG]; // right line
+ [path appendBezierPathWithArcWithCenter:ctrGH // bottom-right curve
+ radius:24.0
+ startAngle:0.0
+ endAngle:90.0];
+ [path lineToPoint:pointA]; // right line