The text to use for calculation.
The length of the text.
The width of the area to put the text.
The size of the font.
The character spacing.
The word spacing.
Suppose there are three words: "ABCDE", "FGH", and "IJKL". Also, suppose the substring until "J" can be included within the width (12 bytes). If word_wrap is HPDF_FALSE the function returns 12. If word_wrap parameter is HPDF_TRUE, it returns 10 (the end of the previous word).
If not NULL, parameter is set to the real width of the text. If NULL, parameter is ignored.
On success, returns byte length which can be included within specified width. Otherwise, returns 0.
Calculates the byte length which can be included within the specified width.