views:

249

answers:

2

Hey all

Blend seems to crash when I try to edit the template of a RichTextBox (even blend 3.)

I need an alternative that can display bold, highlighted, italic text of different colors etc.

Is there anything like this?

+1  A: 

RichTextBox is for editing formatted text. If you're just trying to display text, you can just use a TextBlock:

<TextBlock>
    <TextBlock FontWeight="Bold">I am bold</TextBlock>
    <TextBlock> and I am not</TextBlock>
</TextBlock>

And if your document is complex enough, you can stick it inside a DocumentViewer.

That said, have you tried taking the simplest possible RichTextBox and editing the template in Blend? Does that still crash?

HTH, Kent

Kent Boogaart
yes i have, but it still crashes. it is a known issue in blend -trouble is i need a template for this as it is for a LOB application.
bluebit
+1  A: 

It may not be "pure" but you can use the old Windows.Forms RichTextBox inside your WPF window if you prefer it. I've done it and it works pretty well.

Johan Danforth