Is it possible to add a custom font from a referenced folder (blue one)?
By doing this, my fonts are not recognized in the application. Did I miss something...? Thanks a lot!
EDIT: @Simon Degn: It doesn't work this way either.
I removed the path from Info.plist:
And from my PCH:
I have 6 exceptions rising without message when I launch my app:
For your information I was previously with unreferenced folder (yellow one) and it was working nicely. I'd just like to switch to the referenced folder mode from now on. If that is possible.
Not sure if it's too late to responsed but you're nearly there.
When specifying the font in the info.plist, you're correct in specifying it as the following (where Assets/Font/Averia_Sans_Libre
is the folder reference prefix)
Assets/Font/Averia_Sans_Libre/*.ttf
When you load the app, if you run the following you can see if the font has been loaded:
NSLog(@"All fonts: %@", [UIFont familyNames].description);
Then to use the font, use the following with the FONT NAME, not the FONT FILE NAME (which is what you've done in your example above).
[UIFont fontWithName:@"Averia Sans Libre" size:@"15"];
You can find the name of the font using the example provided by Simon Degn (below)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With