一些常用的宏定义
来源:互联网 发布:网络直销怎么做 2017 编辑:程序博客网 时间:2024/05/19 03:27
#define kScreenHeight [UIScreen mainScreen].bounds.size.height //屏幕的高度
#define kScreenWidth [UIScreen mainScreen].bounds.size.width //屏幕的宽度
//通过三色值获取颜色对象
#define rgb(r,g,b,a) [UIColor colorWithRed:r/255.0 green:g/255.0 blue:b/255.0 alpha:a]
#define ColorWithImgName(str) [UIColor colorWithPatternImage:[UIImage imageNamed:str]]
//设备型号
#define SystemVersionFloat [[UIDevice currentDevice].systemVersion floatValue]
//判断字符串是否为空
#define strIsEmpty(str) (str == nil || [str length]<1 ? YES : NO )
//取文件
#define mainBundle(fileName,fileType) [[NSBundle mainBundle] pathForResource:fileName ofType:fileType]
//设置字体
#define sysFont(f) [UIFont systemFontOfSize:f]
#define boldSysFont(f) [UIFont boldSystemFontOfSize:f]
- 一些常用的宏定义
- 一些常用的宏定义
- 一些常用的宏定义
- 一些常用的宏定义
- 常用的一些宏定义
- 一些可以常用的宏定义
- iOS 一些常用的宏定义
- 位操作的一些常用宏定义
- 一些常用的定义文件
- 一些Java的常用定义
- 一些常用的宏定义(很有用,很有效噢)
- 一些常用的宏定义(很有帮助)
- IOS开发中常用的一些宏定义
- Cocos2dx常用的一些宏定义和头文件
- QString的一些常用定义方法
- 常用的宏定义
- 常用的宏定义
- 常用的宏定义
- C# --习题笔记02
- Nginx从入门到精通阅读笔记2
- CNN: Single-label to Multi-label
- word2010中如何去掉标题前面的小黑点
- Android实现下载图片并保存到SD卡中
- 一些常用的宏定义
- 提升网站排名的外链,你知道怎么做吗?
- HDU 1551 Cable master 二分
- Sizer布局组件2
- cocos2dx批处理文件
- HDU 1698-Just a Hook(线段树_区间更新+lazy标记)
- Saving Key-Value Sets保存到Preference
- java.sql.SQLException: Query returned non-zero code: 12, cause: FAILED: Hive Internal Error: java.la
- UDP的机制