I'm using the new RichTextBox control in SL4Beta and want to create styles for paragraphs and runs (blocks and inlines). I noticed that I can create a style for a <Block/>
, like so:
<Style x:Key="lvl2Paragraph" TargetType="Block">
<Setter Property="FontFamily" Value="Times New Roman"/>
<Setter Property="FontStyle" Value="Italic"/>
<Setter Property="FontSize" Value="22"/>
</Style>
But I can't set that to a <Paragraph/>
as The member "Style" member is not recognized or not accessible. Like this:
<RichTextBox TextWrapping="Wrap">
<Paragraph Style="{StaticResource lvl2Paragraph}">
Can't set a style for a paragraph.
</Paragraph>
</RichTextBox>
Is there anyway to make "Style" exposed for the RichTextBox? I'm open to all ideas.