What is the name of the default system font on the iPhone?
I would like to retrieve this for customizing a UIView
.
Category UIFontSystemFonts for UIFont (UIInterface.h) provides several convenient predefined sizes.
@interface UIFont (UIFontSystemFonts)
+ (CGFloat)labelFontSize;
+ (CGFloat)buttonFontSize;
+ (CGFloat)smallSystemFontSize;
+ (CGFloat)systemFontSize;
@end
I use it for chat messages (labels) and it work well when I need to get size of text blocks.
[UIFont systemFontOfSize:[UIFont labelFontSize]];
Happy coding!