Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1700
Why I create a ParagraphNode to begin ?
posted

Hello,

I have a richTextDocument, I insert some lines with bold and some without.

I have a small screen sapce for this document, so I don't want to have 2 lines at the beginning.

My code is this one :

public ContextViewModel()
{
data = new RichTextDocument { IsReadOnly = true };
csBold = new CharacterSettings() { Bold = true };
CharacterSettings csBigSize = new CharacterSettings() { FontSize = new Extent(20, ExtentUnitType.LogicalPixels) };
pn = createParagraphNode();

InsertDetails();
}

void InsertDetails()
{
AddText(pn, csBold, "Version : ");
AddText(pn, null, Version.ToString());
pn = createParagraphNode();
}

Is there a way to remove it ?

Regards