Jelajahi Sumber

Revert hack for for improve center paragraph in thml2pdf library. Don't run well

Juan Carlos Raña 15 tahun lalu
induk
melakukan
edaacb5256
1 mengubah file dengan 1 tambahan dan 12 penghapusan
  1. 1 12
      main/inc/lib/html2pdf/html2pdf.class.php

+ 1 - 12
main/inc/lib/html2pdf/html2pdf.class.php

@@ -2829,18 +2829,7 @@ if (!defined('__CLASS_HTML2PDF__'))
 			$this->style->setPosition($this->pdf->x, $this->pdf->y);
 			$this->style->FontSet();
 			
-			if ($this->style->value['text-indent']>0) $this->pdf->x+= $this->style->value['text-indent'];
-			
-			// Hack for improve center paragraph by Juan Carlos Raña			
-			$parent_w = $this->pdf->w - $this->pdf->lMargin - $this->pdf->rMargin;				
-			if ($parent_w>$w)
-			{				
-				if ($this->style->value['text-align']=='center')		$this->pdf->x = $this->pdf->x + ($parent_w-$w)*0.5;
-			}
-			
-			$this->style->setPosition($this->pdf->x, $this->pdf->y);
-			//
-			
+			if ($this->style->value['text-indent']>0) $this->pdf->x+= $this->style->value['text-indent'];	
 			
 			return true;
 		}