Hello Fuse Community,
i have played around but i can’t get the result showed in the screenshot below.
Can anyone help me?
Hello Fuse Community,
i have played around but i can’t get the result showed in the screenshot below.
Can anyone help me?
Could you please show some code that you’ve tried so far?
Hey Uldis,
i tried
<Text>Mit dem <Text>Abschluss</Text> </Text>
<Text>Mit dem <Panel>Abschluss</Panel> </Text>
<Text>Mit dem <Panel><Text>Abschluss</Text> </Panel> </Text>
<Panel>Mit dem <Text>Abschluss</Text> </Panel>
Oh, I see. You would get to the expected result if you used WrapPanel or StackPanel, like so:
<StackPanel Orientation="Horizontal">
<Text Value="One" />
<Text Value="Two" />
</StackPanel>
<WrapPanel>
<Text Value="One" />
<Text Value="Two" />
</WrapPanel>
Split the sentence by those words that need different styles, and apply those styles to the separate Text
elements.
Hope this helps!
Hello Uldis,
i tried Stackpanel and WrapPanelbut but now have i the problem the text is left alignt.
How can i align the text to center? TextAlignment Center does not work.
<WrapPanel>
<StackPanel Orientation="Horizontal" >
<Text FontSize="10" Value="Mit dem" />
<Text FontSize="10" Value="Abschluss" />
<Text FontSize="10" Value="der" />
<Text FontSize="10" Value="Registrierung" />
<Text FontSize="10" Value="stimmen Sie den" />
</StackPanel>
<StackPanel Orientation="Horizontal">
<Text FontSize="10" Value="Nutzungsbedingungen" />
<Text FontSize="10" Value="und den" />
<Text FontSize="10" Value="Datenschutzbestimmungen" />
<Text FontSize="10" Value="zu" />
</StackPanel>
</WrapPanel>
Hey Uldis,
i think now i got it.
I replaced the WrapPanel and added ContentAlignment=“Center” to the Stackpanels.
And now it looks like the screenshot.