JonasKruckenberg/tauri-symbols

All icons show up as missing glyphs

caesar opened this issue · 5 comments

On first launching the app, all symbols show as missing glyphs. See screenshot.

macOS 12.4

Screenshot 2022-08-10 at 15 40 56

Interesting! Do you have the SF family of fonts installed on your machine? (Is be installed by default unless you did some fancy font magic) I have a stock macOS 12.4 VM and it works fine on that, so maybe we can troubleshoot why it isn't on your setup.

Well now I'm confused.

So, the short answer is yes, I do have fonts installed. But…

Since opening this issue, it's started working. In the meantime, I installed Apple's SF Symbols Beta app, so I assume that probably added the fonts if they were missing. The package certainly seems to contain the fonts.
On the other hand, I don't see why they'd have been missing, and I didn't see any signs of that elsewhere in the system – you'd think the main system font missing would cause some visible issues!

So now I'm not sure how I can debug this, since it's working now. Hmmmm.

Alright, I tried to replicate this with a fresh macOS Ventura VM and it does seem like the SF Symbols Fonts are actually not installed by default, but rather are installed as part of the SF Symbols 4 beta app installation process :/ This is a bit annoying. Maybe we can bundle the actual font files? Dunno how that would work out legality-wise though. Or maybe there is a command one can execute to install the fonts on first run or something 🤔

That's interesting.

Looking at Apple's developer docs, it looks like the normal way to use it isn't as a font, but rather by doing something like:

Image(systemName: "multiply.circle.fill")

So if the icon font isn't bundled with the OS, it means it isn't very useful to use in 3rd-party apps (unless it can be bundled with the app). That's a pity.

That is a pity indeed 😕 I'm currently looking into maybe installing the font like a native dependency. So just like webview2 on windows, we would install it on first run if it wasn't already available. But I have yet to find a way that doesn't include the whole SF Symbols app.