Monday, July 8, 2013
iOS custom Font for UILabel
- Add your custom font files into your project using Xcode as a resource
- Add a key to your
Info.plistfile calledUIAppFonts. - Make this key an array
- For each font you have, enter the full name of your font file (including the extension) as items to the
UIAppFontsarray - Save
Info.plist
@implementation CustomFontLabel
- (id)initWithCoder:(NSCoder *)decoder
{
if (self = [super initWithCoder: decoder])
{
[self setFont: [UIFont fontWithName: @"Chalkduster" size: self.font.pointSize]];
}
return self;
}
@end
http://www.google.com/fonts/
Subscribe to:
Comments (Atom)