-1

I need to use a custom font in a QuickLook extension.

In the main application where the extension is embedded, I already use this font without problems. So I tried to use the key ATSApplicationFontsPath in the Info.plist as well, but that doesn't seem to be enough. The target membership of the font file is checked for both the app and the extension target.

But NSFont(name: "MyCustomFont", size: 14.0) returns nil and NSFontManager.shared.availableFonts does not contain the font. (It does in the main app though)

Is this even possible and if so, how?

D. Mika
  • 2,577
  • 1
  • 13
  • 29

1 Answers1

0

Ok, it looks like I had the entry in the info.plist in the wrong place. ‍♂️ It was not at root level.

After I corrected that, the font was loaded and used.

D. Mika
  • 2,577
  • 1
  • 13
  • 29