scrollView.subviews.map { (var view) -> () in if (view is UIButton) { view.removeFromSuperview() }}
分类:
编程语言 时间:
2015-06-18 11:09:09
阅读次数:
195
效果如下:ViewController.h1 #import 2 #import 3 4 @interface ViewController : UIViewController5 @property (strong, nonatomic) IBOutlet UIButton *btnPlayMov...
分类:
其他好文 时间:
2015-06-17 19:54:36
阅读次数:
123
UIButton *testButton = [UIButton buttonWithType:UIButtonTypeSystem]; [testButton setFrame:CGRectMake(self.view.frame.size.width/2, self.view.frame....
分类:
移动开发 时间:
2015-06-17 15:06:05
阅读次数:
196
关于UILabel和UIButton有的时候需要添加下划线,一般有两种方式通过默认的NSMutableAttributedString设置,第二种就是在drawRect中画一条下划线,本文就简单的选择第一种,第二种有兴趣的可以自己研究一下。UILabel设置下划线: UILabel *labe...
分类:
移动开发 时间:
2015-06-17 09:23:28
阅读次数:
156
基本属性 1.frame;坐标;title;titlecolor;字体颜色;titleShadowColor:字体阴影;image:图片; backgroundImage:背景图片; 2.forstate状态:这个参数决定了标题、图像或其他属性将在何种状态下显现 UIControlStat...
分类:
其他好文 时间:
2015-06-15 18:25:17
阅读次数:
74
效果如下:ViewController.h1 #import 2 3 @interface ViewController : UIViewController4 @property (strong, nonatomic) UIButton *btnShadow;5 6 @endViewControl...
分类:
其他好文 时间:
2015-06-15 12:50:11
阅读次数:
77
效果如下:ViewController.h1 #import 2 3 @interface ViewController : UIViewController4 @property (strong, nonatomic) UIButton *btnTitleEdgeInsets;5 6 @endVi...
分类:
其他好文 时间:
2015-06-15 12:36:40
阅读次数:
194
效果如下:ViewController.h1 #import 2 3 @interface ViewController : UIViewController4 @property (strong, nonatomic) UIButton *btnState;5 6 @endViewControll...
分类:
其他好文 时间:
2015-06-15 12:36:09
阅读次数:
278
在给UIbutton绑定target嘚时候会遇到传递参数的问题,但默认的参数是一个(id)sender- (void)noteBtnClicked:(id)sender {} 其实就是UIButton自身,也就只能利用UIButton自身的属性进行传值,貌似也只有这一个tag可以办到于是可以这样:....
分类:
其他好文 时间:
2015-06-15 10:45:51
阅读次数:
181
#import "BaseView.h"#import "UIImage+resize.h"#import "NSString+Check.h"#import "UIButton+WebCache.h"#define kOne 10#define kTwo 20#define kThree 30#d...
分类:
其他好文 时间:
2015-06-13 18:23:23
阅读次数:
95