what is fastest way to change text color?

R

Ryan Liu

Then next question is:

I am try to write my own, but is there classes or open src code to handle
RTF format file in C#?

Thanks a million,
Ryan


Nicholas Paldino said:
Ryan,

You could always write an engine that would parse RTF files and change
the color on the fly. That's the only way I can think of doing it outside
of the RichTextBox.

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

Ryan Liu said:
Hi,

I want to change keywords text color in a text editor. I select
RichTextBox
and use its Select() method to select keywords line by line, one by one,
then change its color.

this.Select(start,length) ;
this.SelectionColor = color ;

But turns out it is very slow for big file. Is there better way to do so?

Thanks a lot in advance!
Ryan
 
N

Nicholas Paldino [.NET/C# MVP]

Ryan,

You could always write an engine that would parse RTF files and change
the color on the fly. That's the only way I can think of doing it outside
of the RichTextBox.

Hope this helps.
 
L

Lebesgue

How about asking such questions someone who gives answers in milliseconds,
like uncle google? http://www.google.com/search?hl=en&q=rtf+c#
http://www.codeproject.com/cs/library/nrtftree.asp

Ryan Liu said:
Then next question is:

I am try to write my own, but is there classes or open src code to handle
RTF format file in C#?

Thanks a million,
Ryan


"Nicholas Paldino [.NET/C# MVP]" <[email protected]>
дÈëÓʼþ
Ryan,

You could always write an engine that would parse RTF files and
change
the color on the fly. That's the only way I can think of doing it
outside
of the RichTextBox.

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

Ryan Liu said:
Hi,

I want to change keywords text color in a text editor. I select
RichTextBox
and use its Select() method to select keywords line by line, one by
one,
then change its color.

this.Select(start,length) ;
this.SelectionColor = color ;

But turns out it is very slow for big file. Is there better way to do so?

Thanks a lot in advance!
Ryan
 
R

Ryan Liu

Hi,

I want to change keywords text color in a text editor. I select RichTextBox
and use its Select() method to select keywords line by line, one by one,
then change its color.

this.Select(start,length) ;
this.SelectionColor = color ;

But turns out it is very slow for big file. Is there better way to do so?

Thanks a lot in advance!
Ryan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top