Skip to content

DSaladinCH/fontawesome-wpf

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

82 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Logo

FontAwesome for WPF

WPF Controls with FontAwesome Icons

GitHub issues GitHub license NuGet version (DSaladin.FontAwesome.WPF)

"Buy Me A Coffee"

Download · Report Bug · Request Feature

About This Project

FontAwesome Website: FontAwesome Website
Current FontAwesome Version: 6.4.0
Official FontAwesome Changelog: GitHub Changelog
Package Changelog: GitHub Changelog \

How to use

Step 1 - Include in Window / UserControl / ResourceDictionary

xmlns:fa="https://dsaladin.dev/products/fontawesome/wpf/xaml"

Step 2 - Set icon in Control

<Label fa:Content.Icon="SolidArrowUp" />
<Button fa:Content.Icon="SolidArrowUp" />

FontAwesome Controls

This package also contains two custom controls.

FontAwesome Controls

<fa:FontAwesomeBox Icon="SolidArrowUp" FlipOrientation="Horizontal" Rotation="10" />
<fa:FontAwesomeImage Icon="SolidArrowUp" />

Troubleshooting

Error CS8630 - Invalid 'nullable' value

The package uses nullable values (for example string?), this was officially added in C# 8.0. This version (or higher) is used from .NET Core 3.x onwards.
In .NET Framework the default is C# 7.3. So in order to use the package you have to set the project language version to 8.0 (or higher).

Set language version

  1. Open the .csproj file
  2. Add <LangVersion>8.0</LangVersion> to the PropertyGroup

For more information visit https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/configure-language-version