$txt->paragraph width as MAXwidth ;)
Status: Beta
Brought to you by:
areibens
Hi,
sometimes i create text with paragraph($text, $width,
$height). My problem: if a word is too long, it runs
out of the width-box...
Is there any reason for this behaviour?
btw: thanx a lot for the great work!!!
*schorsch*
Paragraph uses the sub _text_fill_line($self,$text,$width,$over) with the "over" parameter set to True, which means it will put as many words that fit PLUS the last word.
You may call _text_fill_line() with $over=0 to find out how many words will actually fit before calling paragraph.
//Andreas