Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Word wrap calculation for printing
Message
De
17/11/2003 12:13:01
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00850670
Message ID:
00850684
Vues:
20
>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.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform