Xcode 9 custom fonts not working

后端 未结 5 955
一向
一向 2020-12-19 00:13

Custom fonts not working in Xcode 9. However if I open the same project in Xcode 8, the custom fonts work as expected

I\'ve ran this piece of code to ensure the font

5条回答
  •  臣服心动
    2020-12-19 00:57

    Had the same problem after opening project in Xcode 9, solved it by reincluding the fonts. (deleted them, cleaned project, included them, built project).

    Altough you got them checked in the target, but not visible to chose as custom font, you can try to specify the localization (above target check) to 'base' or some, it made them visible in Storyboards after that, but unable to load in code (at least in my case). However, reincluding is imo better way to go, it made everything OK.

提交回复
热议问题