This is a migrated thread and some comments may be shown as answers.

Fonts not exporting to RTF

12 Answers 76 Views
RichTextBox (obsolete as of Q3 2014 SP1)
This is a migrated thread and some comments may be shown as answers.
Walter
Top achievements
Rank 1
Walter asked on 05 Aug 2014, 06:49 PM
I have a RichTextBox control on my form.  I change the font and type some text.  It looks fine on screen.  I export the RadDocument to RTF using the RtfFormatProvider.  It changes the font to Calibri, no matter what I initially set it at.  Is there some trick to getting the RadDocument to export out the proper font?

12 Answers, 1 is accepted

Sort by
0
Dimitar
Telerik team
answered on 06 Aug 2014, 02:02 PM
Hello Walter,

Thank you for writing.

We have a similar to this case already reported. However the issue in this case appear only when the rtf document is imported back to the richtextbox. This is why I wanted to ask you if you are importing the document or you are opening it with a different editor (WordPad)?

More information about the already logged item is available here.

I am looking forward to your reply.

Regards,
Dimitar
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
0
Walter
Top achievements
Rank 1
answered on 07 Aug 2014, 02:48 PM
1. Write document in Word 2010. Set font to Arial.
2. Import into Telerik RichTextBox.  It looks fine, correct font and all.
3. Export it to RTF.
4. View RTF code.  The font has changed to Calibri.  Also, the font sizes are all reset to be the same if there were fonts with different point sizes.

A workaround that kind of works, but not always is that after importing document into the RTF box, if you change the first letter to a different font, and then export it, it will SOMETIMES keep the rest of the document as the original font.  It appears that it does better when there are mixed fonts. 







0
Dimitar
Telerik team
answered on 11 Aug 2014, 02:26 PM
Hi Walter,

Thank you for the detailed description.

I was able to reproduce the issue and it appears that this is the same issue that is already logged. I have updated the issue internal description which will allow our developers to consider your description as well.

Unfortunately I cannot provide you with a workaround for the issue.

Do not hesitate to contact us if you have other questions.

Regards,
Dimitar
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
0
Mahmoud
Top achievements
Rank 1
answered on 26 Aug 2015, 08:32 PM

hello

how to make less spaceing in line  radrichtexteditor

0
Dimitar
Telerik team
answered on 27 Aug 2015, 01:28 PM
Hello Mahmud,

Thank you for writing.

You can use the ChangeParagraphLineSpacing method:
void button_Click1(object sender, EventArgs e)
{
    this.radRichTextEditor1.Document.Selection.SelectAll();
    this.radRichTextEditor1.ChangeParagraphLineSpacing(2);
}

Let me know if you have additional questions.

Regards,
Dimitar
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Mahmoud
Top achievements
Rank 1
answered on 27 Aug 2015, 01:33 PM
i need clear radrichtexteditor im trying tow match but not fine 
0
Mahmoud
Top achievements
Rank 1
answered on 27 Aug 2015, 02:06 PM
i need The biggest size form radrichtexteditor c# winforms 
0
Dimitar
Telerik team
answered on 28 Aug 2015, 08:29 AM
Hi Mahmud,

I am sorry, I am having issues understanding both of these questions. Could you please elaborate?

Regards,
Dimitar
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Mahmoud
Top achievements
Rank 1
answered on 28 Aug 2015, 05:03 PM

first  one i need remove or clear data in radrichtexteditor 

and in need large for textbox same word document size paper 

0
Mahmoud
Top achievements
Rank 1
answered on 29 Aug 2015, 01:14 PM

hello

i'm trying many time i need clear data in radrichtexteditor in c# 

0
Mahmoud
Top achievements
Rank 1
answered on 30 Aug 2015, 08:16 AM

hello 

i need help for radrichtexteditor  , when make brows from my pc doc insert document when showing in radrichtexteditor

he cant same style ?

0
Dimitar
Telerik team
answered on 31 Aug 2015, 08:50 AM
Hello Mahmud,

If you want to clear the data you can just create new document:
void button_Click1(object sender, EventArgs e)
{
    this.radRichTextEditor1.Document = new RadDocument();
}

The following snippet shows how you can set the page size:
this.radRichTextEditor1.Document.LayoutMode = DocumentLayoutMode.Paged;
//custom size
this.radRichTextEditor1.Document.SectionDefaultPageSize = new Size(800, 1000);
//A4
this.radRichTextEditor1.ChangeSectionPageSize(PaperTypeConverter.ToSize(PaperTypes.A4));

In addition, I do not understand the question from your last post. Could you, please describe this case in details?

I hope this will be useful.

Regards,
Dimitar
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
RichTextBox (obsolete as of Q3 2014 SP1)
Asked by
Walter
Top achievements
Rank 1
Answers by
Dimitar
Telerik team
Walter
Top achievements
Rank 1
Mahmoud
Top achievements
Rank 1
Share this question
or