【发布时间】:2011-10-20 11:29:38
【问题描述】:
如何在 WPF XAML 资源字典中使用制表符和回车符?
这对我不起作用:
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:system="clr-namespace:System;assembly=mscorlib"
>
<system:String x:Key="test_Key">Tab doesnt work\tTest\rTest</system:String>
</ResourceDictionary>
当我通过 FindResource("test_key") 检索它时,制表符和回车符都被删除了。
【问题讨论】:
标签: wpf xaml resourcedictionary