0

I've added custom fonts to my xcode project and they show up just fine when I run the app in the simulator but when I run it on my iPhone they don't show up. This is the code in my AppDelegate.m file

[[UINavigationBar appearance] setTitleTextAttributes: [NSDictionary dictionaryWithObjectsAndKeys:
[UIColor colorWithRed:23.0/255.0 green:97.0/255.0 blue:115.0/255.0 alpha:1.0], UITextAttributeTextColor,
[UIFont fontWithName:@"Lily Script One" size:23.0], UITextAttributeFont, nil]];
danielbeard
  • 9,120
  • 3
  • 44
  • 58
Brandon Houlihan
  • 209
  • 1
  • 2
  • 6
  • The first step would be to check if `[UIFont fontWithName:...]` returns `nil` or not ... – Martin R Aug 14 '13 at 19:04
  • Make sure you've actually included the font in the bundle and added the required .plist entry. The simulator has more fonts available than the device since the simulator is actually OSX. [Can I embed a custom font in an iPhone application?](http://stackoverflow.com/a/3198821/168493) – Marcus Adams Aug 14 '13 at 19:09
  • most likely you forgot to check "copy items into destination groups folder" try re-importing the font and making sure to check that off – Ben Aug 14 '13 at 19:10
  • @ben that's exactly what happened, thanks for the help! – Brandon Houlihan Aug 16 '13 at 13:36
  • @BrandonHoulihan I do it all the time and the errors never make sense. Always the first thing I check now – Ben Aug 17 '13 at 17:59

0 Answers0