iOS Question custom fonts trouble

sorex

Expert
Licensed User
Longtime User
Hello,

Today I finished another app that had a custom font in it.

While everything worked fine on my iPhone I went for a test drive on an iPad.

To my surprise the app crashed.

The problem appears that the font which has a name with a space in it required an underscore (_) in the font create command on the iPhone.

On the iPad the underscore can be dropped but then it crashes on the iPhone due to the missing underscore.

How can I work around this issue besides changing the font name in the ttf file?
 

sorex

Expert
Licensed User
Longtime User
this issue was resolved with the help of @ilan, thanks!

altho it doesn't make much sense :)

I renamed the file and left the space in the name in the font.createnew2 command.

Even more bizar...

When I list the available fonts it still list them with an underscore or without the space.
 
Upvote 0
Top