New topic: drawing formatted text/StyledTextPrinter ?
<http://forums.realsoftware.com/viewtopic.php?t=39288> Page 1 of 1 [ 1 post ] Previous topic | Next topic Author Message David Blythe Post subject: drawing formatted text/StyledTextPrinter ?Posted: Thu Jun 02, 2011 10:05 am Joined: Mon May 17, 2010 8:27 am Posts: 20 Hello and Help, I'm trying to take the text entered in a TextArea and draw it on a picture that was opened from a file using: Code: f=GetFolderItem("RentAgFront.tif") p=New Picture(1700, 2200, 32) p.HorizontalResolution=200 p.VerticalResolution=200 p=Picture.Open(f) I was able to draw text from TextFields using: Code: dim stsh As StringShape Dim d as New Group2D stsh.Text=TextField1.text stsh.x=1470 stsh.y=970 d.Append stsh p.Graphics.DrawObject d It's possible for the user to type enough characters into the TextArea to go off the page, so I need to put a margin on the text when it draws on the picture. I tried this: Code:dim stp As StyledTextPrinter stp = TextArea1.styledTextPrinter (p.graphics , 468) stp.DrawBlock 175, 650, 144 but it didn't show up on the picture. How do I make the StyledTextPrinter go to the picture? Or is there another method for drawing text within a margin? Top Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending Page 1 of 1 [ 1 post ] -- Over 1500 classes with 29000 functions in one REALbasic plug-in collection. The Monkeybread Software Realbasic Plugin v9.3. http://www.monkeybreadsoftware.de/realbasic/plugins.shtml [email protected]
