UIView 定制边框
作者:
雪中客 | 来源:发表于
2016-03-02 14:46 被阅读165次// [recommendedTimeBackgroundView.layer setMasksToBounds:YES];
// [loginButton.layer setCornerRadius:5.0]; //设置矩形四个圆角半径
//边框
[recommendedTimeBackgroundView.layer setBorderWidth:1.0]; //边框宽度
CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceRGB();
CGColorRef colorref = CGColorCreate(colorSpace,(CGFloat[]){0.8,0.8,0.8, 1 });
[recommendedTimeBackgroundView.layer setBorderColor:colorref];//边框颜色
CGColorRelease(colorref);
CGColorSpaceRelease(colorSpace);
本文标题:UIView 定制边框
本文链接:https://www.haomeiwen.com/subject/wnenkttx.html
网友评论