1.導入 Songti.ttc?文件到工程目錄下
2. Build Phases ->Copy Bundle Resources 加入Songti.ttc文件
3. Info.plist 配置文件加入Fonts provided by application 設(shè)置
4. 使用方法 Log出字體名稱并使用
使用 nameLabel.font = [UIFont fontWithName:@"STSongti-SC-Black" size:18.0];
? 字體名稱獲取
??for(NSString *fontfamilyname?in?[UIFontfamilyNames])? ?{
? ? ? ? NSLog(@"familyName:'%@'", fontfamilyname);? ? ??
????? ? ??for(NSString *fontName in?[UIFont fontNamesForFamilyName:fontfamilyname])? {
? ? ? ? ? ? NSLog(@"? fontName:'%@'",fontName);
? ? ? ? }
? ? ? ? NSLog(@"***********");
? ? }