UIBezierPath AutoLayout

对于基于视图框架调整大小的 bezier 路径,覆盖要绘制贝塞尔曲线路径的视图的 drawRect:

- (void)drawRect:(CGRect)frame
{
    UIBezierPath* rectanglePath = [UIBezierPath bezierPathWithRect: CGRectMake(CGRectGetMinX(frame), CGRectGetMinY(frame), CGRectGetWidth(frame), CGRectGetHeight(frame))];
    [UIColor.grayColor setFill];
    [rectanglePath fill];
}