zoukankan      html  css  js  c++  java
  • iOS Button添加阴影 和 圆角

    用iamgeview 加手势代替

     self.headimageview = [[UIImageView alloc] initWithFrame:CGRectMake(IPHONEWIDTH(13), statusRect.size.height+IPHONEWIDTH(16), IPHONEWIDTH(119), IPHONEWIDTH(119))];

       

        self.headimageview.image=UIimageName(@"homeimages");

        //    阴影

        self.headimageview.layer.shadowColor = Colorgray.CGColor;

        self.headimageview.layer.shadowOffset = CGSizeMake(2, 2);

        self.headimageview.layer.shadowOpacity = 0.7;

        self.headimageview.layer.shadowRadius = 3;//阴影半径,默认3

        

        self.headimageview.userInteractionEnabled = YES; //响应点击

        UITapGestureRecognizer *tapGesture = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(showLeftMenu)];

        [self.headimageview addGestureRecognizer:tapGesture];

        

        [self.view addSubview:self.headimageview];

     

     

     

     

     

     

    -(void)showLeftMenu{

     

    }

  • 相关阅读:
    3.redis认证
    2.redis-help使用,基本命令
    安卓使用merge标签和include优化UI布局
    安卓数据存储之ContentProvider
    安卓数据存储之SQLLite
    安卓数据存储之SharePreference
    安卓数据存储之sdcard存储
    java解析json之gjson和fastjson
    Android Volley完全解析(一),初识Volley的基本用法
    使用Pull解析Xml文件
  • 原文地址:https://www.cnblogs.com/xujiahui/p/9544524.html
Copyright © 2011-2022 走看看