mac-cain13 / R.swift

Strong typed, autocompleted resources like images, fonts and segues in Swift projects
MIT License
9.5k stars 764 forks source link

Doesn't render fonts in R.generated file #845

Closed Rylaa closed 1 year ago

Rylaa commented 1 year ago

I have defined the fonts in info.plist but it doesn't add them to r.generated.

mac-cain13 commented 1 year ago

Do the fonts work when you try to use them without R.swift, but with the standard Apple provided APIs?

Rylaa commented 1 year ago

yes it works fine

mac-cain13 commented 1 year ago

That is interesting. Could you provide a bit more information about the setup;

synecdochenoire commented 1 year ago

I have the same problem.

  1. static let jetBrainsBold = UIFont(name: "JetBrainsMono-Bold", size: 26)
  2. JetBrainsMono-Bold.ttf downloaded from Google Fonts
  3. It is included in the target and added to Info.plist
  4. Yes, there was no problem with adding strings, colors and images