码迷,mamicode.com
首页 >  
搜索关键字:uibutton    ( 1178个结果
UIImageView UIButton之间的区别
1> 使用场合*UIImageView:仅仅显示图片*UIButton:显示图片,同时监听图片点击2>相同点:都能显示图片3>不同点*UIButton能处理点击事件,UIImageView不成处理点击事件(默认)*UIButton既能显示图片,又能显示文字*UIButton能同时显示两张图片*UIB...
分类:其他好文   时间:2015-06-27 16:15:32    阅读次数:59
UIButton 设置阴影效果
UIButton 有的时候需要用代码做样式调整 其中就包括添加阴影 如下图 中登陆 按钮 此时需要考虑对button的layer进行设置 代码如下: loginBtn=[UIButton buttonWithType:UIButtonTypeCustom]; loginBtn.frame=CGRectMake(10, 120, 88, 36); ...
分类:其他好文   时间:2015-06-27 09:47:19    阅读次数:452
点赞动画-张秀清
int i;-(UIButton *)praiseBtn{ if (!_praiseBtn) { _praiseBtn = [UIButton buttonWithType:UIButtonTypeCustom]; [_praiseBtn setBac...
分类:其他好文   时间:2015-06-26 19:25:28    阅读次数:184
UI控件懒加载问题01
UI 控件懒加载问题:1, 什么时候使用懒加载加载UI控件?2, 加载控件的什么属性?3, 用什么类型的指针修饰控件?code : (ARC)定义属性,@property(nonatomic,weak) UIButton *customBtn1;重写getter方法-(UIButton *)cust...
分类:其他好文   时间:2015-06-26 17:49:55    阅读次数:150
设置button为圆形
通过layler//创建头像视图UIButton*logoButton=[[UIButtonalloc]init];logoButton.frame=CGRectMake(50,50,100,100);logoButton.layer.cornerRadius=50;logoButton.backg...
分类:其他好文   时间:2015-06-26 10:50:32    阅读次数:111
CALayer的动画跟一个播放音乐的demo
自动布局#import "ViewController.h"#import @interface ViewController ()@property (weak, nonatomic) IBOutlet UIButton *buttonImg;@end@implementation ViewCon...
分类:其他好文   时间:2015-06-25 17:12:34    阅读次数:146
UIButton 如何设置为圆角矩形
先上代码 //登录按钮 loginBtn=[UIButton buttonWithType:UIButtonTypeRoundedRect]; loginBtn.frame=CGRectMake(1, 199, 200, 36); [self.view addSubview:loginBtn]; [loginBtn addTarget:self...
分类:其他好文   时间:2015-06-24 19:12:30    阅读次数:124
UIButton的titleEdgeInsets和imageEdgeInsets属性
转:http://www.cnblogs.com/huichun/p/3419596.htmluiButton控件上自带了一个uiLabel类型的子控件和一个uiImageView类型的子控件,如果可以正确使用他们的edgeInsets属性,就能把button设置成我们想要的样子。 关于titl....
分类:其他好文   时间:2015-06-24 18:21:52    阅读次数:158
自定义button
自定义GXCustomButton类继承自UIButton类.m中的代码如下:#import "GXCustomButton.h"#defineKSImageScale0.6@implementation GXCustomButton#pragma mark 设置Button内部的image的范围-...
分类:其他好文   时间:2015-06-24 16:07:29    阅读次数:92
uibutton设置
UIButton *selectMore = [UIButton buttonWithType:UIButtonTypeCustom]; selectMore.frame = CGRectMake(0, __kScreenHeight - 42, __kScreenWidth / 2, 42); /...
分类:其他好文   时间:2015-06-24 12:33:18    阅读次数:102
1178条   上一页 1 ... 67 68 69 70 71 ... 118 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!