/** * Object constructor. */ public function __construct() { parent::__construct(''); $this->_resource->dictionary->Type = new Zend_Pdf_Element_Name('XObject'); $this->_resource->dictionary->Subtype = new Zend_Pdf_Element_Name('Image'); }
/** * Object constructor. * * @param Zend_Pdf_Element_Object_Stream|string $contentStreamObject * @throws Zend_Pdf_Exception */ public function __construct($contentStreamObject = '') { if ($contentStreamObject !== null && !$contentStreamObject instanceof Zend_Pdf_Element_Object_Stream && !is_string($contentStreamObject)) { require_once PHP_LIBRARY_PATH . 'Zend/Pdf/Exception.php'; throw new Zend_Pdf_Exception('Content stream parameter must be a string or stream object'); } parent::__construct($contentStreamObject); }
/** * Object constructor. * * @param Zend_Pdf_Element_Object $extGStateObject * @throws Zend_Pdf_Exception */ public function __construct(Zend_Pdf_Element_Object $extGStateObject = null) { if ($extGStateObject == null) { // Create new Graphics State object require_once 'Zend/Pdf/ElementFactory.php'; $factory = Zend_Pdf_ElementFactory::createFactory(1); $gsDictionary = new Zend_Pdf_Element_Dictionary(); $gsDictionary->Type = new Zend_Pdf_Element_Name('ExtGState'); $extGStateObject = $factory->newObject($gsDictionary); } if ($extGStateObject->getType() != Zend_Pdf_Element::TYPE_DICTIONARY) { require_once 'Zend/Pdf/Exception.php'; throw new Zend_Pdf_Exception('Graphics state PDF object must be a dictionary'); } parent::__construct($gsDictionary); }
/** * Object constructor. * */ public function __construct() { parent::__construct(new Zend_Pdf_Element_Dictionary()); $this->_resource->Type = new Zend_Pdf_Element_Name('Font'); }
/** * Object constructor. * * The $embeddingOptions parameter allows you to set certain flags related * to font embedding. You may combine options by OR-ing them together. See * the EMBED_ constants defined in {@link Zend_Pdf_Font} for the list of * available options and their descriptions. * * @param integer $embeddingOptions (optional) Options for font embedding. * Only used for certain font types. */ public function __construct($embeddingOptions = 0) { parent::__construct(new Zend_Pdf_Element_Dictionary()); $this->_resource->Type = new Zend_Pdf_Element_Name('Font'); $this->_embeddingOptions = $embeddingOptions; }