Tuesday, April 21, 2009

Trips&Ticks: Do you know how you can break text in any text control of WPF?

Seems it is easy - we can use a LineBreak in code or as XAML element, but what can we do if we want to present this in attribute of XAML? Little searching shows that we should use XSLT and hexadecimally encoded value to present a literal.
<TextBlock Text="Line 1&#x0A;Line 2" />

No comments: