Open lkomanetz opened 1 week ago
I haven't considered unpacked msix application, but still MAUI provides an API to use embedded fonts, so MAUI should extract embedded fonts from dll and use them automatically. I'll check and create an issue to MAUI repository if it's related to maui
@enisn I remember checking the output folder and not seeing the FontAwesome font files. My assumption was that since they were embedded resources they would be part of the EXE but it was just an assumption. If I can find time I'll try to look into it some more and help out but I've been swamped lately.
Using v2.8.1 I added the FontAwesome icon pack to my MAUI project and made sure to include the
AddFontAwesomeIconFonts
extension method in theMauiProgram.cs
file. During development, and when creating an MSIX package, the icons that I was using were working without any issue. When I built the project as an unpackaged app the icons were only showing as little squares (indicating it couldn't find them).To fix the issue I had to download the font files from
src/UraniumUI.Icons.FontAwesome/Resources/Fonts
into theResources/Fonts
folder in my MAUI project, make sure those files wereMauiFont
resources that were set to copy always, and then register them in the default way (using the same aliases as the extension method uses).The expectation, since they are embedded resources, was that everything would work as both an MSIX package or unpackaged app without having to make any code changes.