FontAwesome.Portable Nuget Package
FontAwesome.Portable is an attempt att creating a Nuget package with a portable dependency property which allows you to use FontAwesome symbols in some common user controls in your Universal/Store Windows and Windows Phone 8.1 apps (so many names...)
PM> Install-Package FontAwesome.Portable
It is dependent on the FontAwesome Nuget package, but only uses the /fonts/fontawesome-webfont.ttf file, so you can safely delete the other files (until I figure out how to delete them as part of the Nuget package installation).
Usages:
<Page x:Class="WpTest.MainPage" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:fa="using:FontAwesome.Portable" mc:Ignorable="d" Background="{ThemeResource ApplicationPageBackgroundThemeBrush}"> <Grid> <StackPanel HorizontalAlignment="Center" VerticalAlignment="Center"> <Button fa:FontAwesome.Symbol="Windows" /> <Button fa:FontAwesome.Symbol="Thumbs_o_up">YES</Button> <TextBlock Margin="10" HorizontalAlignment="Center" FontSize="20" fa:FontAwesome.Symbol="Pencil" /> <TextBlock Margin="10" HorizontalAlignment="Center" FontSize="20" Text="NO" fa:FontAwesome.Symbol="Thumbs_o_down" /> </StackPanel> </Grid> <Page.BottomAppBar> <CommandBar> <AppBarButton Label="report"> <AppBarButton.Icon> <FontIcon fa:FontAwesome.Symbol="Car" /> </AppBarButton.Icon> </AppBarButton> </CommandBar> </Page.BottomAppBar> </Page>
The FontAwesome.Symbol property
The fa:FontAwesome.Symbol property is an attached property to set the icon you want to use. It displays a dropdown with all the icons in the FontAwesome package, easy to select. You can optionally enter a Text or Content text, which will be rendered to the right of the icon (see screenshot at bottom).
The code snippet above should result in something like this on a Windows Phone.
Licenses
The package is fully open source and is GPL friendly. You can use it for commercial projects, open source projects, or really just about whatever you want. All brand icons in FontAwesome are trademarks of their respective owners.