Thus far I have always chosen the font Courier New because all letters are the same width. Is there any way of determining how "long" a string will be when using other fonts? I would like a way of checking the string's actual length so I can format a printout properly when using fonts that have letters with varying widths.
MrConfused
0
Light Poster
Recommended Answers
Jump to PostWhat programming language are you using?
You could usehttp://us2.php.net/manual/en/function.strlen.php
And then create an if statement to use this display with this font or that display with another font based on …
All 4 Replies
techniner
2
Posting Pro
invisal
381
Search and Destroy
techniner
2
Posting Pro
MrConfused
0
Light Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.