|
-
July 17th, 2001, 04:47 PM
#1
Centering Multiple Line Text
I have this current chunk of code:
xProper = (Preview.ScaleWidth - TextWidth(Subtitle.Text)) / 2
yProper = (Preview.ScaleHeight - TextHeight(Subtitle.Text)) / 2
Preview.CurrentX = xProper
Preview.CurrentY = yProper
Preview.print Subtitle.Text
... where 'Subtitle' is a multiline text box.
If I put a single line in, it works great! But as soon as I put in a second line the alignment starts to fail. The first line will appear center, but subsequent lines appear on the right border.
I figure I could parse the text based on a newline, but it seems like there should be an easier way.
Many thanks for any help!
Hoag
-
July 17th, 2001, 07:10 PM
#2
Re: Centering Multiple Line Text
Hello:
Before you run the program, I must set MultiLine to true and Alignment to 2 in Properties
Good Luck
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|