自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(9)
  • 收藏
  • 关注

原创 placeholder设置字体大小与颜色

很简单就能实现 [textField setValue:[UIColor greenColor] forKeyPath:@"_placeholderLabel.textColor"]; [textField setValue:[UIFont boldSystemFontOfSize:13] forKeyPath:@"_placeholderLabel.font"];

2017-08-09 18:02:17 1047

原创 iPhone手机屏幕大小及分辨率

以前一直找,现在自己保存起来

2017-07-22 17:19:24 759

原创 ios成长之路 Navigation的统一布局

项目中都会有自己风格的返回键,重写方法可以不用每个页面都去写一次// 统一设置标题颜色+(void)initialize{[[UINavigationBar appearance] setTitleTextAttributes:[NSDictionary dictionaryWithObject:[UIColor whiteColor] forKey:UITextAttributeTextCol

2017-07-22 17:03:55 384

原创 ios新手入门之UITextField左边空格

// UITextField输入开始时,左边回空出一小段距离,看起来比较好UILabel * leftView = [[UILabel alloc] initWithFrame:CGRectMake(15,0,7,26)];leftView.backgroundColor = [UIColor clearColor];self.textF.leftView = leftView;self.tex

2017-07-22 16:31:35 827

原创 iOS新手入门之点击空白处回收键盘

点击空白处实现键盘回收首先需要建一个与屏幕等大的UIView, 然后把这个UIView添加到这个屏幕上, 把创建的UITextField作为UIView的子视图(添加到UIView上)#import "AppDelegate.h"// 定义宏 设置成与屏幕等宽 方便使用

2015-10-07 16:38:11 666

原创 iOS新手入门之UITextField

// 创建一个UITextField UITextField *textField = [[UITextField alloc] initWithFrame:CGRectMake(100, 100, 200, 50)]; // 设置背景颜色 textField.backgroundColor = [UIColor greenColor]; // 设置占位符(输入框内直接显示出来的文本 如:输入

2015-10-07 14:57:03 223

原创 iOS新手入门之UIButton

UIButton *button = [UIButton buttonWithType:UIButtonTypeCustom];// 设置button的位置以及大小button.frame = CGRectMake(100, 100, 100, 100);// 设置按钮(button)的背景颜色button.backgroundColor = [UIColor grayColor];

2015-10-07 11:27:46 235

原创 iOS新手入门之UILable

UILable可以在上面显示字体#import "AppDelegate.h"@interface AppDelegate ()@end@implementation AppDelegate- (void)dealloc{ [_window release]; [super dealloc];}- (BOOL)application:(UIApplication *)applic

2015-10-07 11:06:07 351

原创 iOS新手入门之UIView

#import "AppDelegate.h"// 获取屏幕的高度 宽度// 自定义宏#define kScreenWidth [UIScreen mainScreen].bounds.size.width#define kScreenHeight [UIScreen mainScreen].bounds.size.height@interface AppDelegate ()@end@imp

2015-10-07 10:40:03 280

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除