MXCornerRadius
MXCornerRadius copied to clipboard
可以指定位置设置圆角吗
现在是没有,请教如何在代码中修改,可以指定圆角的位置,比如左上角右上角这样
竟然有这个需求啊,我这边可以加的,不过这几天有事情,但保证三天内完成,你要是很急的话 可以 直接在代码里改的,在 '''
- (UIImage *)getCornerRadiusImage { CGRect imageRect = _imageView.bounds; UIGraphicsBeginImageContextWithOptions(imageRect.size, NO, 0); [[UIBezierPath bezierPathWithRoundedRect:imageRect cornerRadius:_mxCornerRadius] addClip]; [_imageView.layer renderInContext:UIGraphicsGetCurrentContext()]; UIImage *cacheImage = UIGraphicsGetImageFromCurrentImageContext(); UIGraphicsEndImageContext(); return cacheImage; } ''' [[UIBezierPath bezierPathWithRoundedRect:imageRect cornerRadius:_mxCornerRadius] addClip]; 改成[UIBezierPath bezierPathWithRoundedRect: raddi:...]有个类方法 你可以 改下哈
我不急,假期结束后我再调试这里,到时候再来看看,谢谢啦