plane icon Welcome to Microsoft Flight Simulator’s SDK Q&A Platform!

You have questions regarding the SDK? DevMode Tools? SimConnect? You would like to submit an idea for future improvements, seek help or exchange knowledge? You’re in the right place.

Please take a moment to read the platform’s guidelines before you get started!


For HUDs issues management, please read the article here !

question

Flysimware avatar image
Flysimware asked MRiquier edited

Custom font for xml gauges

If i use a custom font for HTML gauge i know i can include the font in my asset and have the CSS file point to it. But if i have a XML gauge i have no way to point to the font from what i know. So it only shows the font if it is registered/installed front in windows. So my question is when we release a product through the Market Place how can we install font to windows? Or is there a way to point to a font in my assets for an xml gauge?

aircraft
10 |10000 characters needed characters left characters exceeded

Up to 5 attachments (including images) can be used with a maximum of 4.8 MiB each and 23.8 MiB total.

SonantAlpaca avatar image
SonantAlpaca answered

Hello,

@MRiquier can you please take a look? :)

10 |10000 characters needed characters left characters exceeded

Up to 5 attachments (including images) can be used with a maximum of 4.8 MiB each and 23.8 MiB total.

MRiquier avatar image
MRiquier answered MRiquier edited

Hello @Flysimware, to reference a font in an XML Gauges you need to use the tag <FontFace>NameOfTheFont</FontFace>. Please note that the NameOfTheFont is the name of the font and not the name of the .ttf file (most of the time they are identical but not always).

-> Exemple here, the name of the font is 'Dot Matrix', so you reference it as

<FontFace>Dot Matrix</FontFace>

Then you add your font files in a 'fonts' folder at the root of your package so users can have access to it.1629726722166.png


1629726722166.png (38.3 KiB)
10 |10000 characters needed characters left characters exceeded

Up to 5 attachments (including images) can be used with a maximum of 4.8 MiB each and 23.8 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 5 attachments (including images) can be used with a maximum of 4.8 MiB each and 23.8 MiB total.