【发布时间】:2015-05-11 23:25:03
【问题描述】:
我正在尝试在没有任何特定属性的 XAML TextBlock 中显示各种 Unicode 字符:
<TextBlock Text="{Binding MyString}" Foreground="Black" />
这适用于我的 Windows 8.1 系统上的所有脚本,表情符号字符除外:
由于这些符号在 Segoe UI Symbol 字体中可用,我只是将其添加到FontFamily:
<TextBlock Text="{Binding MyString}" Foreground="Black"
FontFamily="Segoe UI Symbol" />
但是,现在一些西里尔符号被破坏了:
所以我尝试启用几种字体,包括composite fonts listed on MSDN:
<TextBlock Text="{Binding MyString}" Foreground="Black"
FontFamily="Lucida Sans Unicode, Lucida Grande, Segoe UI Symbol,
Open Sans, Arial, Microsoft Sans Serif, Tahoma,
Courier New, Times New Roman, Global User Interface,
Portable User Interface" />
但我得到完全相同的结果:
我该如何解决这个问题? 全局用户界面难道不应该给我一个适合所有角色的后备方案吗?当我不指定 FontFamily 时,我的 TextBlock 可以使用什么?
【问题讨论】: