您的位置:首页 > 产品设计 > UI/UE

UIView添加圆角阴影

2014-10-14 22:06 330 查看
   UIView *upView =[[UIView
alloc]initWithFrame:CGRectMake(15,
self.view.frame.size.height-60,
self.view.frame.size.width-30,
44)];
    [upView
setBackgroundColor:[UIColor
whiteColor]];//设置背景色
    [[upView layer] setShadowOffset:CGSizeMake(1,
1)];
    upView.layer.cornerRadius=3;//设置圆角
    [[upView
layer] setShadowRadius:5];//设置圆角阴影
    [[upView
layer] setShadowOpacity:1];
    [[upView
layer] setShadowColor:[UIColor
blackColor].CGColor];//设置阴影颜色
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  uiview