Programming Forums

Programming Forums (http://www.programmingforums.org/forumindex.php)
-   Visual Basic .NET (http://www.programmingforums.org/forum19.html)
-   -   Different fonts in my rtf box (http://www.programmingforums.org/showthread.php?t=10959)

bigguy Aug 6th, 2006 12:02 AM

Different fonts in my rtf box
 
Hey yall. I am making a word processor type thing. I need to know how to make my text in the rtf box at different fonts that I'm assignign and when I save the f8ile and the user opens it it still shows the same type of font and tab's, spaces etc etc Thanks in advance

Kennedy Aug 6th, 2006 3:18 AM

Perhaps I am wrong in this. . . but I have had a similar situation with my program. From all the documentation I have read, you cannot change fonts/colors for individual lines (or partial lines) in richedit, listbox, etc predefined types. You will have to create a window and control all the painting in that window yourself. If I am wrong, we will both learn something. . . If I am correct, we'll talk off-line and perhaps I'll share some of my code with you.

melbolt Aug 11th, 2006 12:25 AM

normally you can't have multiples by default, but its possible with a custom control or a wrapper such as this: http://www.vbaccelerator.com/home/ne...er/article.asp

this guy shows you how to make a font picker combo and have it apply to your richtextbox control. he wrote a little wrapper in which he gives all the source and a tutorial to boot.

an alternative would be to purchase a control to add into your tools such as this:
http://www.bennet-tec.com/btproducts...xt/alltext.htm

enjoy.

bigguy Aug 17th, 2006 12:50 PM

No, I dont know what I did, but I just needed to open a letter. and I used different fonts in wordpad, and when I opened the letter in my program, it shows everything the same way it was created.

melbolt Aug 20th, 2006 3:13 PM

Quote:

Originally Posted by bigguy
No, I dont know what I did, but I just needed to open a letter. and I used different fonts in wordpad, and when I opened the letter in my program, it shows everything the same way it was created.

so you created a wordpad file and now are trying to print it out inside of your textbox in your app?


All times are GMT -5. The time now is 12:17 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC