UIFont with custom font fails with Nil

后端 未结 7 2002
孤街浪徒
孤街浪徒 2020-12-31 10:59

I\'m trying to add a custom font to my project in Xcode 4.2, but whenever I try to use it, I get a error that the object is nil.

I have done the following:
1) Ad

7条回答
  •  南笙
    南笙 (楼主)
    2020-12-31 11:37

    Find your font (maybe with another name) and use this name.

        for (NSString *familyName in [UIFont familyNames]) {
            for (NSString *fontName in [UIFont fontNamesForFamilyName:familyName]) {
                NSLog(@"%@", fontName);
            }
        }
    

提交回复
热议问题