Patrik Fröhler
Patrik Fröhler

Reputation: 1291

Custom font OpenSans in visual studio not displaying XAML, UWP

I am trying to get a "custom" font working in a UWP XAML C# project Open Sans Extrabold Italic I have added it to my project and it shows up correctly in Properties but when I select it, it doesn't work. (All the default fonts work.)

I have also tried changing the XAML to FontFamily="/Assets/Fonts/OpenSans-ExtraBoldItalic.ttf#OpenSans"

What am I doing incorrectly?

enter image description here

Upvotes: 0

Views: 536

Answers (1)

Faywang - MSFT
Faywang - MSFT

Reputation: 5868

The FontName you used is not correct, it should be "Open Sans", so please change it as

FontFamily="/Assets/Fonts/OpenSans-ExtraBoldItalic.ttf#Open Sans"

Upvotes: 1

Related Questions