Пример #1
0
 /**
  * Constructor
  *
  * @param PdfDocument $pdfDocument
  */
 public function __construct(PdfDocument $pdfDocument)
 {
     $this->_pdfDocument = $pdfDocument;
     if ($fontpath = $pdfDocument->getFontPath()) {
         if (substr($fontpath, -1) != '/' && substr($fontpath, -1) != '\\') {
             $pdfDocument->setFontPath($fontpath . '/');
         }
     } elseif (is_dir(dirname(__FILE__) . '/Fonts')) {
         $pdfDocument->setFontPath(dirname(__FILE__) . '/Fonts/');
     }
 }