我有这个标签。我想居中并为其赋予橙色,但是不知道如何。
<Label>
<Label.FormattedText>
<FormattedString>
<Span Text="R$"
FontAttributes="Bold"
FontSize="Large"/>
<Span x:Name="CalculoParcial"
FontAttributes="Bold"
FontSize="Large"/>
</FormattedString>
</Label.FormattedText>
</Label>
答案 0 :(得分:1)
如何添加Backgroundcolor,HorizontalOptions和HorizontalTextAlignment?
<Label BackgroundColor="Orange" HorizontalOptions="FillAndExpand" HorizontalTextAlignment="Center">
<Label.FormattedText>
<FormattedString>
<Span Text="R$"
FontAttributes="Bold"
FontSize="Large"
/>
<Span x:Name="CalculoParcial"
FontAttributes="Bold"
FontSize="Large"/>
</FormattedString>
</Label.FormattedText>
</Label>