(One last update to change to permanent URL on my site)
I’ve seen the question of how to embed fonts in Axure come up again and again over the years here on these forums. There’s a tried and true method to do so, but it involves a few steps usually some tinkering depending on the instructions you found and if you’re using the same file type as the instructions. I’ve wanted to make the process easier and finally over the past two weeks I sat down and got a working prototype together that makes the whole process easier.
Why is this easier?
It does everything for you. It reads the font file you upload and extracts the font name from it. It checks the type of font file (even if you uploaded it without an extension!) and gives you the appropriate MIME type to use, so you don’t have to even know what that is or look it up. It even detects the font weight from the file, if applicable. In the end it gives you a fully formatted text blob that you only need to copy/paste into Axure. If any of the values it finds are wrong or don’t seem right, you can modify them and the text blob will use your updates.
However…
I’m calling this v0.1 so there’s still a few known issues, but nothing that should prevent it from working entirely.
- If you’re using a WOFF2 file, it can’t detect the font name or weight. This is because the library I’m currently using for parsing the file doesn’t support WOFF2.
- If you want to leave off font-weight, you might need to remove some extraneous text at the end. This will be fixed.
- Only WOFF, OTF, TTF and WOFF2 (partially) are supported at this time. If you have a font type you want to use but can’t, let me know and I’ll add it if I can.
What else?
- In case you care, the font is never upload to a server. This works 100% client-side. You could even download the page (and the linked JS files) and it should even work offline.
- I’ll be adding the option to grab a font file from a URL in addition to uploading it from your computer.