Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Word wrap calculation for printing
Message
From
17/11/2003 12:13:01
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00850670
Message ID:
00850684
Views:
19
>I have forms which must be translated programmatically into postscript files. Labels may be word-wrapped. I know you can use TXTWIDTH and FONTMETRIC to get the pixel length of a string.
>
>Can anyone tell me how to apply this to determine where the breaks might be in a label, given the width and height of the label?

You may start with a loop, adding content of the label word by word, and then calculating the width after each word, until the length of the visual representation grows more than the label length.

I'm not sure the PostScript rendering engine will yield the same results as what you get from TxtWidth, though. You may be off by one word here and there.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform