码迷,mamicode.com
首页 > 移动开发 > 详细

iOS Font

时间:2015-10-15 11:19:13      阅读:170      评论:0      收藏:0      [点我收藏+]

标签:

1. 非常棒的查看字体样貌网站: http://iosfonts.com

     1. 查看设备支持字体: 

        NSArray *familyNames = [NSMutableArray arrayWithArray:[UIFont familyNames]];

     1. 需要导入第三方字体库link? 有些字库可以从OS X中导入 https://support.apple.com/en-hk/HT201375

     1. 导入第三方库,将.otf加入bundle中,配置info.plist Fonts ‘provided by application‘字段。例如AppleSDGothicNeo-Medium.otf添加进bundle中,则需要在info.plist中添加此,font name便是AppleSDGothicNeo-Medium。检测字库是否被导入:例如应用中用到的所有字库,其实这些字体系统都有

         UIFont *font1 = [UIFont fontWithName:@"Avenir-Roman" size:12];

         UIFont *font2 = [UIFont fontWithName:@"Helvetica Neue" size:12];

         UIFont *font3 = [UIFont fontWithName:@"HelveticaNeue-Medium" size:12];

         UIFont *font4 = [UIFont fontWithName:@"AppleSDGothicNeo-Regular" size:12];

         UIFont *font5 = [UIFont fontWithName:@"AppleSDGothicNeo-Medium" size:12];

         UIFont *font6 = [UIFont fontWithName:@"AppleSDGothicNeo-SemiBold" size:12];

         UIFont *font7 = [UIFont fontWithName:@"AppleSDGothicNeo-Bold" size:12];

         UIFont *font8 = [UIFont fontWithName:@"AppleSDGothicNeo-UltraLight" size:12];

iOS Font

标签:

原文地址:http://www.cnblogs.com/ouyangfang/p/4881770.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!