UIView 圆形边框

简介: UIView 圆形边框
UIView *bfPanel = [[UIView alloc]initWithFrame:CGRectMake(x, y, width, height)];  
bfPanel.layer.masksToBounds = YES;  
bfPanel.layer.borderWidth  =1;  
bfPanel.layer.cornerRadius = 10;  
bfPanel.layer.borderColor= [[UIColor colorWithRed:0.52 green:0.09 blue:0.07 alpha:1] CGColor];  
[mainView addSubview:bfPanel];  
y +=height+10;  
相关文章
给UIView添加阴影
首先加入头文件#import ,并载入CoreGraphics.framework框架。 [[btn layer] setShadowColor:[[UIColor blackColor] CGColor]]; [[btn layer] setShadowOffset:CGSizeMake(5, 5)]; [[btn layer] setShadowOpacity:1.0];
857 0
UIImageView加上圆角
UIImageView加上圆角
55 0
|
UED 缓存 异构计算
UIImageView添加圆角的几种方法
喜欢我的可以关注收藏我的个人博客:RobberJJ 创建一个UIImageView对象: UIImageView * poImgView = [[UIImageView alloc] init]; 第一种方法 poImgView.
974 0
设置UIView的简单阴影效果
<pre style="margin-top:0px; margin-bottom:0px; padding:0px; white-space:pre-wrap; word-wrap:break-word; line-height:18px; background-color:rgb(245,245,245); font-family:'Courier New'!important"><s
1074 0
|
9月前
添加渐变色
添加渐变色
50 0
|
前端开发 JavaScript 容器
第165天:canvas绘制圆环旋转动画
canvas绘制圆环旋转动画——面向对象版 1、HTML 注意引入Konva.js库 1 DOCTYPE html> 2 3 4 5 使用Konva绘制圆环旋转动画 6 7 8 9 10 11 12 13 14 15 //创建舞台 16 var stage=new Konva.
2091 0

热门文章

最新文章