We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Keep current style when adding a new paragraph

Thread ID:

Created:

Updated:

Platform:

Replies:

118822 Apr 13,2015 06:08 AM Apr 14,2015 07:09 AM WPF 2
loading
Tags: RichTextBoxAdv
Chris
Asked On April 13, 2015 06:08 AM

Hi all,

I'm trying to implement RichTextBox with a toolbar (instead of ribbon).
So far so good, except when a define a style (font-family, font-size) with binding on combobox, when I add a new paragraph by pressing return, the style return to initial style and don't keep the one I defined previously. I does the same in bullet list.

How can I prevent this behaviour ? I was looking for a "onNewParagraph" event, but I don't see it, to save and reload the CurrentParagraphStyle ... Will I have to create it ? How to do it if so ?

Thanks

Narendran Srinivasan [Syncfusion]
Replied On April 14, 2015 02:46 AM

Hi Chris

Thanks for choosing Syncfusion products,

At this moment we don’t have support to preserve paragraph formatting equivalent to ms word. So that whenever an paragraph is created the default font name and size has retrieved from RichTextBoxAdv control. As a workaround you can achieve this scenario by changing the font name and size of RichTextBoxAdv control while creating a paragraph or changing the style of the selected text.

Please let me know if you have any other question

Regards,
Narendran



Narendran Srinivasan [Syncfusion]
Replied On April 14, 2015 07:09 AM

Hi Chris

Please ignore our previous update.

At this moment we don’t have support to preserve paragraph formatting equivalent to ms word. So that whenever a paragraph is created the default font name and size has retrieved from RichTextBoxAdv control. As a workaround you can achieve this scenario by changing the font name and size of RichTextBoxAdv control while creating a paragraph or changing the style of the selected text. For your reference we have prepared a sample to illustrate the same. Please find the sample from below link.

Sample link:
Sample

Please let me know if you have any other question

Regards,
Narendran


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;