![]() ![]() This works for everything generated in code, including system created views. If it is, I use the original methods, otherwise return a font of my choosing (in this case Helvetica Neue with UltraLight weight for regular and italic requests, and Medium weight for bold requests). Return [UIFont I do in this example is replace the three system font methods with my own and test to see if the system version is 7 or up. + (UIFont *)ln_italicSystemFontOfSize:(CGFloat)fontSize + (UIFont *)ln_boldSystemFontOfSize:(CGFloat)fontSize + (UIFont *)ln_systemFontOfSize:(CGFloat)fontSize Orig = class_getClassMethod(, = class_getClassMethod(, swiz) Method orig = class_getClassMethod(, swiz = class_getClassMethod(, swiz) Here is the Objective-C Runtime solution: UIFont (CustomSystemFont)
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |