摘要: UIStepper * stepper = [[UIStepper alloc]initWithFrame:CGRectMake(50, 100, 150, 40)]; //********最小值和最大值 stepper.maximumValue = 100; ste... 阅读全文
posted @ 2015-11-24 01:09 GXcoder 阅读(311) 评论(0) 推荐(0) 编辑
摘要: 创建分段选择器 UISegmentedControl * sc = [[UISegmentedControl alloc]initWithFrame:CGRectMake(50, 100, 200, 30)]; [sc insertSegmentWithTitle:@"第一页" ... 阅读全文
posted @ 2015-11-24 01:06 GXcoder 阅读(885) 评论(0) 推荐(0) 编辑
摘要: 创建ProgressView UIProgressView * progressView = [[UIProgressView alloc]initWithFrame:CGRectMake(50, 100, 200, 10)]; progressView.progressView... 阅读全文
posted @ 2015-11-24 01:02 GXcoder 阅读(762) 评论(0) 推荐(0) 编辑
摘要: 创建提示框 //创建提示框 //标题 提示内容 代理对象 按钮 UIAlertView * alertView = [[UIAlertView alloc]initWithTitle:@"警告" message:@"萨达姆已经做好战斗准备" delegate:self ca... 阅读全文
posted @ 2015-11-24 00:58 GXcoder 阅读(491) 评论(0) 推荐(0) 编辑
摘要: 创建UIActivityIndicatorView UIActivityIndicatorView * AIV = [[UIActivityIndicatorView alloc]initWithFrame:CGRectMake(50, 50, 50, 50)]; //设置样式 ... 阅读全文
posted @ 2015-11-24 00:52 GXcoder 阅读(418) 评论(0) 推荐(0) 编辑
摘要: UIActionSheet在iOS8.3之后已不建议使用。 可以使用UIAlertController+UIAlertControllerStyleActionSheet获得同样的效果创建UIActionSheet UIActionSheet * as = [[UIActionSheet al... 阅读全文
posted @ 2015-11-24 00:47 GXcoder 阅读(296) 评论(0) 推荐(0) 编辑
摘要: 把NavigationController设为根视图控制器 FirstViewController * firstVC = [[FirstViewController alloc]init]; UINavigationController * nc = [[UINavig... 阅读全文
posted @ 2015-11-24 00:36 GXcoder 阅读(164) 评论(0) 推荐(0) 编辑
摘要: UIViewController的生命周期- (void)loadView{} 用于创建self.view- (void)viewDidLoad{} self.view创建完毕- (void)viewWillAppear:(BOOL)animated{}视图即将显示- (void)viewDidAp... 阅读全文
posted @ 2015-11-20 01:46 GXcoder 阅读(180) 评论(0) 推荐(0) 编辑
摘要: 创建一个UIImageView //创建UIImageView 根据图片大小 UIImageView * imageView = [[UIImageView alloc]initWithFrame:CGRectMake(50, 80, size.width, size.height)];... 阅读全文
posted @ 2015-11-20 01:11 GXcoder 阅读(218) 评论(0) 推荐(0) 编辑
摘要: UIView的几个主要属性1 /*2 CGRect frame;3 4 CGRect bounds;5 6 CGPoint center;7 8 CGAffin... 阅读全文
posted @ 2015-11-20 01:02 GXcoder 阅读(177) 评论(0) 推荐(0) 编辑