使用Template10时,特殊字符(如Ü,Ä,Ö)在运行时无法正确显示 [英] Special characters (like Ü,Ä,Ö) are not correctly displayed at runtime in case of using Template10
问题描述
使用用于UWP应用程序的Template10时出现问题.如果我想在设计时显示特殊字符,一切似乎都还可以.在运行时,如截图所示,特殊字符将无法正确显示.
Have an issue by using the Template10 for UWP apps. If i want to display special characters at design time everything seems to be ok. At runtime special characters would not be displayed correctly as you can see in screenshots.
<!-- page header -->
<controls:PageHeader Content="Übersicht">
<controls:PageHeader.SecondaryCommands>
<AppBarButton Click="{x:Bind ViewModel.GotoSettings}" Label="Settings" />
<AppBarButton Click="{x:Bind ViewModel.GotoPrivacy}" Label="Privacy" />
<AppBarButton Click="{x:Bind ViewModel.GotoAbout}" Label="About" />
</controls:PageHeader.SecondaryCommands>
</controls:PageHeader>
例如"Ü bersicht" -> VisualStudio设计器"Ü bersicht" ->运行时?bersicht"
For example "Übersicht" -> VisualStudio Designer "Übersicht" -> Runtime "?bersicht"
设计器视图
运行时
推荐答案
如果您使用字符串资源(.resw文件),这些字符也将正确显示:
If you use string resources (.resw files), the characters will also appear correctly:
XAML:x:Uid ="..."
XAML: x:Uid="..."
C#:ResourceLoader.GetForViewIndependentUse().GetString("...");
C#: ResourceLoader.GetForViewIndependentUse().GetString("...");
这篇关于使用Template10时,特殊字符(如Ü,Ä,Ö)在运行时无法正确显示的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!