matthewrdev/fa2cs

Using it in Xaml

Joebu opened this issue · 3 comments

Joebu commented

I tried using it in XAML as your demo but it doesn't work (setting the text in code behind does work)

<Label Text="{x:Static fontAwesome:FontAwesomeIcons.AmazonPay}"/>

Hi @Joebu,

Are you applying the correct FontAwesome font file to the label?

For fa-amazon-pay, you will need to apply the FontAwesome 5 Brands font family.

See: https://docs.microsoft.com/en-us/xamarin/xamarin-forms/user-interface/text/fonts#setting-the-font-in-xaml

Also, can you elaborate on "doesn't work"?

Does the code compile? Does the app crash at runtime? Does the icon simply not render?

Joebu commented

Sorry I didn't set the right font