title: Why is my custom font not working in Xcode?
body: <p>So this problem is all over the internet, but I've completed the steps of nearly every listed successful solution and I want to make sure I ask with my specific case before I have to try reinstalling my macOS. I'm trying to use a custom font in my iOS app, Montserrat. The font file name is &quot;Montserrat-Regular.ttf&quot;. I began by adding the file to my project, with the project selected as a target:</p>
  <p><a href="https://i.stack.imgur.com/BesRN.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/BesRN.png" alt="enter image description here" /></a></p>
  <p>I also added it to my Info.plist file in &quot;Fonts provided by application&quot;:</p>
  <p><a href="https://i.stack.imgur.com/zRS70.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/zRS70.png" alt="enter image description here" /></a></p>
  <p>And it is in my Copy Bundle Resources:</p>
  <p><a href="https://i.stack.imgur.com/WMcks.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/WMcks.png" alt="enter image description here" /></a></p>
  <p>Despite all this, when I try to use the font for a Text object in my SwiftUI app like so:</p>
  <pre><code>Text(&quot;Welcome Back!&quot;)
      .position(x: (geometry.size.width / 2), y: 160.0)
      .foregroundColor(.white)
      .font(Font.custom(Constants.FontStrings.montserratReg, size: 30.0))
  </code></pre>
  <p>I still get the default font. When I run a for loop to print out all the font families I have, interestingly, Montserrat doesn't show up:
  <a href="https://i.stack.imgur.com/Fffuj.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Fffuj.png" alt="enter image description here" /></a></p>
  <p>Even though it is listed in my Font book. Actually several of the fonts in my Font book didn't show up here, I'm not sure if that's relevant:</p>
  <p><a href="https://i.stack.imgur.com/DYjB6.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/DYjB6.png" alt="enter image description here" /></a></p>