Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
List Box and Non-Proportional fonts
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Titre:
List Box and Non-Proportional fonts
Versions des environnements
Visual FoxPro:
VFP 6 SP5
Divers
Thread ID:
00967462
Message ID:
00967462
Vues:
73
Hi all

This list box in my mover I have populated and is working well except for calculating field
width. I have tried to use FONTMETRIC(6, ...) as FONTMETRIC(7, ...) returns too large a number
that I cannot fit all the columns. I tried to use Courier New as a proportionate font, then I
end up with less columns though much better than FONTMETRIC(7, ...). I have shortage of screen
real estate as I am supposed to target 800x600 monitors.

Can I have an intermediate size calculation? I have tried to up the calculation by 1.15 so
that some more space is available than then average. The calculation goes something like this
ALLTRIM(STR(FONTMETRIC(6, ;
			THIS.Icntmover1.lstAvailable.FontName, ;
			THIS.Icntmover1.lstAvailable.FontSize) * LEN(&lcTemp.) * 1.15))
This above I am then using to create the column width string to be poulated in the ListBox.

Plus using non-proportionate fonts renders the numeric values to display towards the left and
uneven depending on the size of the value as the numerals are padded with spaces on the left.
Also in date column final 2 digits of the year are chopped off due to Average Font Calculation
in FONTMETRIC().

Please advise.
Regards
Bhavbhuti
___________________________________________
Softwares for Indian Businesses at:
http://venussoftop.tripod.com
___________________________________________
venussoftop@gmail.com
___________________________________________
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform