如何在XAML中的TextBlock末尾添加空格?(Windows 10,UWP)

Vik*_*mkó 1 xaml windows-runtime winrt-xaml windows-10 uwp

Text="Some text:" 我想在冒号之后添加一个空格.

我尝试过xml:space="preserve", 但似乎都没有效果.

我知道可以通过添加保证金来完成,但我很好奇是否有另一种方式.

Ive*_*Ive 5

试试这个,它对我有用.

<RelativePanel>
    <TextBlock x:Name="test1" RelativePanel.Below="edLongitude">
        ahoj &#160;  
    </TextBlock>
    <TextBlock x:Name="test2" RelativePanel.Below="edLongitude" RelativePanel.RightOf="test1" Text="nazdar" />
</RelativePanel>
Run Code Online (Sandbox Code Playgroud)