(转载)教你如何在iOS项目中设置各种字体
原文地址:http://www.cnblogs.com/jijiYY/p/4736967.html 在iOS开发中设置字体的方法有很多种,下面为大家介绍比较常用的三种方法 1.使用系统默认提供的字体 系统默认提供的字体主要是指UIFont中提供的字体,其使用代码为: fontLabel.font = [UIFont fontWithName:@"Marion" size:17]; 或者是通过字体详细字典对字体属性进行设置 /* UIFontDescriptorFamilyAttribute:设置字体家族名 UIFontDescriptorNameAttribute :设置字体的字体名 UIFontDescriptorSizeAttribute :设置字体尺寸 UIFontDescriptorMatrixAttribute:设置字体形变 */ UIFontDescriptor *attributeFontDescriptor = [UIFontDescriptor fontDescriptorWithFontAttributes: @{UIFontDescriptorFamilyAttr...