UIFont
2013-01-20 20:10
162 查看
如果我们多处要对字体进行设置,我们可以用宏来做,这样方便我们管理和扩展。
// For text, messages, etc
#define DEFAULT_FONTSIZE 15
#define DEFAULT_FONT(s) [UIFont fontWithName:@"ArialMT" size:s]
#define DEFAULT_BOLDFONT(s) [UIFont fontWithName:@"Arial-BoldMT" size:s]
// For table cells
#define CELL_FONTSIZE 16
#define CELL_FONT(s) [UIFont fontWithName:@"Helvetica-Oblique" size:s]
#define CELL_BOLDFONT(s) [UIFont fontWithName:@"Helvetica-BoldOblique" size:s]
-------------------------------------------------------------
正常:Helvetica
加粗:
"Helvetica-Bold"
"TimesNewRomanPS-BoldMT"
"Arial-BoldMT"
"CourierNewPS-BoldMT"
"Georgia-Bold"
// For text, messages, etc
#define DEFAULT_FONTSIZE 15
#define DEFAULT_FONT(s) [UIFont fontWithName:@"ArialMT" size:s]
#define DEFAULT_BOLDFONT(s) [UIFont fontWithName:@"Arial-BoldMT" size:s]
// For table cells
#define CELL_FONTSIZE 16
#define CELL_FONT(s) [UIFont fontWithName:@"Helvetica-Oblique" size:s]
#define CELL_BOLDFONT(s) [UIFont fontWithName:@"Helvetica-BoldOblique" size:s]
-------------------------------------------------------------
正常:Helvetica
加粗:
"Helvetica-Bold"
"TimesNewRomanPS-BoldMT"
"Arial-BoldMT"
"CourierNewPS-BoldMT"
"Georgia-Bold"
相关文章推荐
- IOS开发之UIFont应用
- UIFont 设置字体
- UIFont
- IOS UIFont 字体大全
- 字体UIFont
- ios-系统字体一览UIFont
- 【读书笔记】UIFont-如何知道字体的PostScript名称
- UIFont & 测量NSString大小
- UI基础:UILabel.UIFont
- iOS UIFont中文字体 -- 中文字体包快速查找
- iOS 使用 UIFont
- UIFont 属性对应
- iOS添加自定义自体 [UIFont fontWithName: size:]
- UIFont
- UIFont的一些特例
- iOS 之UIFont字体大全和样例
- iOS中UIKit——UIFont得到iOS设备上的系统字体
- iOS UIFont 初识
- 【读书笔记】UIFont-动态下载系统提供的多种中文字体网址
- IOS UILabe及UIFont用法总结