iOS
wo890532
这个作者很懒,什么都没留下…
展开
-
学习笔记 键盘处理-不让键盘挡住文本框
@interface MJScrollView () { CGPoint _lastOffset;}@end@implementation MJScrollView#pragma mark - 生命周期方法- (id)initWithFrame:(CGRect)frame{ self = [super initWithFrame:frame];...2014-12-22 23:30:24 · 154 阅读 · 0 评论 -
iOS开发项目篇—10对齐方式
一、关于四个容易混淆属性的对比说明1. textAligment : 文字的水平方向的对齐方式(1) 取值NSTextAlignmentLeft = 0, // 左对齐NSTextAlignmentCenter = 1, // 居中对齐NSTextAlignmentRight = 2, // 右对齐 (...原创 2014-12-25 09:12:53 · 159 阅读 · 0 评论 -
不是controller需要重写init方法 iOS
@implementation HDHostSleep- (instancetype)init { self = [super init]; if (self) { NSArray *array = [[NSBundle mainBundle] loadNibNamed:@"HDHostSleep" owner:self options:nil];...原创 2014-12-08 16:01:05 · 215 阅读 · 0 评论 -
ios 获取屏幕的属性和宽度
app尺寸,去掉状态栏CGRect r = [ UIScreen mainScreen ].applicationFrame;r=0,20,320,460屏幕尺寸CGRect rx = [ UIScreen mainScreen ].bounds;r=0,0,320,480状态栏尺寸CGRect rect; rect = [[UIApplication sharedAp...原创 2014-12-08 16:13:18 · 176 阅读 · 0 评论 -
设置UIView阴影shadow 边框 边框颜色
// Implement viewDidLoad to do additional setup after loading the view, typically from a nib.- (void)viewDidLoad { [super viewDidLoad]; self.view.backgroundColor=[UIColor whiteColor]; ...原创 2014-12-08 16:34:49 · 159 阅读 · 0 评论 -
Corrupt PNG File - The PNG icon file Icon@2x.png appears to be corrupt.
作为iOS 开发者,常遇到一个诡异的上传问题。 好不容易上传了一个app, 第一时间收到的邮件不是 ready for sale ,而是 “The PNG icon file Icon@2x.png appears to be corrupt”. 内容如下: 'Dear developer,We have discovered one or more issues with your ...原创 2014-12-09 14:18:34 · 1159 阅读 · 0 评论 -
ios 如何隐藏状态栏
1. 如果只是想把当前页面的状态栏隐藏的话,直接用下面的代码就可以了 [[UIApplication sharedApplication] setStatusBarHidden:TRUE]; 2. 如果是想把整个应用程序的状态栏都隐藏掉,操作如下: 在info.plist上添加一项:Status bar is initially hidden,value...原创 2014-12-15 10:28:21 · 137 阅读 · 0 评论 -
学习MBProgressHUD
+ (void)showError:(NSString *)error toView:(UIView *)view{ // 快速显示一个提示信息 MBProgressHUD *hud = [MBProgressHUD showHUDAddedTo:view animated:YES]; hud.labelText = error; // 设置图片 ...2014-12-17 23:07:32 · 194 阅读 · 0 评论