View Single Post
Old 10-29-2007, 04:16 PM   #4 (permalink)
bluesaga
Super Moderator
Advanced Programmer 
 
bluesaga's Avatar
 
Join Date: Sep 2007
Posts: 165
Thanks: 0
bluesaga is on a distinguished road
Default

I am not sure how either of these programs work but you could always add the line breaks in yourself with a wordwrap?

Like:
$newtext = wordwrap($text, 8, "\n");

Where 8 is the limit per line and \n is your delimiter.

PHP Code:
$pdf =& new Cezpdf('a4','P');
$pdf->ezSetCmMargins(2,2,2,2);
$pdf->selectFont('./fonts/Helvetica.afm');
$szText ''VEry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text vry lannngge text!";
$pdf->ezText( wordwrap($szText, 20, "\n") );
$pdf->ezStream(); 
It does depend how the class works though, but wordwrap will simply limit it to 20 chars and then add a \n and carry on with the rest of the text...
__________________
Halo 3 Cheats
bluesaga is offline  
Reply With Quote