I have a line of text in a textblock that reads:
\"Detected [gesture] with an accuracy of [accuracy]\"
In WPF, is it possible for me to be able to change th
I know this post is old, but have you tried this?? You can actually add multi colored text, this way in a TextBlock..
Xaml:
foreach (var itm5 in "! Hello World !; %Hello World%".Split(';'))
{
if (txt_Txt.Inlines.Count() > 0)
txt_Txt.Inlines.Add(new Run("\r\n"));
foreach (var letter in itm5)
{
if (char.IsSymbol(letter))
txt_Txt.Inlines.Add(new Run(letter.ToString()) { Foreground = Brushes.Red });
else
txt_Txt.Inlines.Add(new Run(letter.ToString()) { Foreground = Brushes.Black });
}
}