zoukankan      html  css  js  c++  java
  • 关于图片边框或控件圆角的设置

    一、控件圆角的设置:

    self.profileImageView.layer.cornerRadius = 10.0f; 设置圆角,非正圆

    self.profileImageView.clipsToBounds= YES; 将圆角多余部分切除

    headImgView.layer.cornerRadius = headImgView.bounds.size.width/2;  设置圆角,正圆  ;xib适配时可能出现问题,建议代码创建控件

    headImgView.layer.masksToBounds = YES;  将圆角多余部分切除

    二、控件边框的设置:

    self.profileImageView.layer.borderWidth = 3.0f;

    self.profileImageView.layer.borderColor = [UIColor whiteColor].CGColor;

    三、参考链接:

    http://ju.outofmemory.cn/entry/76525

  • 相关阅读:
    React-使用combineReducers完成对数据对拆分管理
    Linux
    Linux
    linux
    linux
    Linux
    Linux
    Linux
    Linux
    Linux 系统基础优化和常用命令
  • 原文地址:https://www.cnblogs.com/sunny-ll/p/6387096.html
Copyright © 2011-2022 走看看