UIBezierPath *path = [UIBezierPath bezierPathWithRoundedRect:roomButton.bounds byRoundingCorners:UIRectCornerBottomRight | UIRectCornerBottomLeft cornerRadii:CGSizeMake(10, 10)];
CAShapeLayer *layer = [CAShapeLayer layer];
layer.frame = roomButton.bounds;
layer.path = path.CGPath;
roomButton.layer.mask = layer;
指定View的几个角为圆角
最新推荐文章于 2021-02-02 14:23:41 发布