摘要: 线程问题我会分成三篇文章来给大家做个详细的讲解 一、线程的概念 1.线程是进程的组成部分,一个进程可以拥有多个线程,一个线程必须有一个父线程; 2.线程拥有自己的堆栈、自己的程序计数器和自己的局部变量,但不再拥有系统资源,它与父线程中的其他线程共享该进程所拥有的全部资源 3.线程是独立运行的,它并不 阅读全文
posted @ 2016-01-30 23:00 Mr~Lin 阅读(446) 评论(0) 推荐(0) 编辑
摘要: 当我想从一个VC跳转到另一个VC的时候,一般会用 - (void)presentViewController:(UIViewController *)viewControllerToPresent animated: (BOOL)flag completion:(void (^)(void))com 阅读全文
posted @ 2016-01-30 21:27 Mr~Lin 阅读(524) 评论(0) 推荐(0) 编辑
摘要: 知识点: 1)UINavigationController 2)UINavigationBar 3)UINavigationItem 4)UIToolBar======================================================一、UINavigationCont... 阅读全文
posted @ 2016-01-06 22:12 Mr~Lin 阅读(550) 评论(0) 推荐(3) 编辑
摘要: #import "ViewController.h"@interface ViewController ()@property (nonatomic,strong) UITextField *tf;@end@implementation ViewController- (void)viewDidLo... 阅读全文
posted @ 2016-01-06 08:47 Mr~Lin 阅读(483) 评论(0) 推荐(0) 编辑
摘要: //1.设置背景 //tf.backgroundColor = [[UIColor blueColor] colorWithAlphaComponent:0.7]; //2.设置输入框的样式 /* UITextBorderStyleNone, 默认样式,无样式 UITextBorderStyleLi 阅读全文
posted @ 2016-01-05 00:01 Mr~Lin 阅读(300) 评论(0) 推荐(0) 编辑
摘要: /* 图层关系 子视图 - 嵌套在父视图之上的视图 父视图 - 被嵌套的视图 视图和视图之间可以层层嵌套 */ UIView *red = [[UIView alloc] initWithFrame:CGRectMake(50, 100, 100, 100)]; red.backgr... 阅读全文
posted @ 2016-01-04 12:51 Mr~Lin 阅读(278) 评论(0) 推荐(0) 编辑
摘要: #import "ViewController.h"// 视图大小#define VIEW_W 60#define VIEW_H 60// 总个数#define kSIZE 6// 每行个数#define kNumber 2// 状态栏#define kStart (20+280)// y间距#de... 阅读全文
posted @ 2016-01-03 21:00 Mr~Lin 阅读(1329) 评论(0) 推荐(0) 编辑
摘要: //UIImageView 用来显示图片的控件 UIImageView *imgView = [[UIImageView alloc]initWithFrame:CGRectMake(10,_label.frame.size.height+10+10, self.window.frame.size... 阅读全文
posted @ 2016-01-03 20:58 Mr~Lin 阅读(408) 评论(2) 推荐(0) 编辑
摘要: //// ViewController.m// 计算器//屏幕的宽和高#define SCREEN_W self.view.frame.size.width#define SCREEN_H self.view.frame.size.height#import "ViewController.h"@i... 阅读全文
posted @ 2016-01-03 14:07 Mr~Lin 阅读(744) 评论(2) 推荐(0) 编辑
摘要: //UIButton - 按钮,可以用来与用户进行交互 //UIButton -> UIControl -> UIView //button一般情况下不使用实例方法创建 /* UIButtonTypeCustom // 自定义按钮类型,也是系统默认值(一般都... 阅读全文
posted @ 2016-01-01 14:27 Mr~Lin 阅读(450) 评论(2) 推荐(1) 编辑