WPF 踩坑笔记7 引用字体文件

<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:theme="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero2">

    <Style x:Key="IconButtonStyle" TargetType="Button">
        <Setter Property="VerticalAlignment" Value="Center"/>
        <Setter Property="FontSize" Value="22"/>
        <Setter Property="Background" Value="Red"> </Setter>
        <Setter Property="FontFamily" Value="/Fonts/#iconfont"/> 字体不出现原因1.字体文件中没有所写的unicode 2.字体文件路径不对;
    </Style>
</ResourceDictionary>
原文地址:https://www.cnblogs.com/wuhailong/p/15136021.html