SetaPDF_Core_XObject_Form Class representing a Form XObject

File: /SetaPDF/Core/XObject/Form.php

Class hierarchy

Implements

Summary

Static Properties

$_xObjects

static protected array SetaPDF_Core_XObject_Form::$_xObjects = array()

An array caching XObject objects


Properties

$_bbox

The BBox rectangle

$_canvas

The canvas object for this form XObject

$_indirectObject

The indirect object of the XObject


Static Methods

create()

freeCache()

static public void SetaPDF_Core_XObject::freeCache ( SetaPDF_Core_Document $document )

Release XObject instances by a document instance.

Parameters
$document : SetaPDF_Core_Document
 

get()

Get an external object by an indirect object/reference.

Parameters
$xObjectReference : SetaPDF_Core_Type_IndirectObjectInterface
 
$subType : string
 
Exceptions

Throws SetaPDF_Exception_NotImplemented


Methods

__construct()

The constructor.

Parameters
$indirectObject : SetaPDF_Core_Type_IndirectObjectInterface
 

cleanUp()

public void SetaPDF_Core_XObject::cleanUp ( void )

Release memory and cycled references.

draw()

public mixed|void SetaPDF_Core_XObject_Form::draw ( SetaPDF_Core_Canvas $canvas [, float $x = 0.0 [, float $y = 0.0 [, float $width = null [, float $height = null ]]]] )

Draw the external object on the canvas.

Parameters
$canvas : SetaPDF_Core_Canvas
 
$x : float
 
$y : float
 
$width : float
 
$height : float
 

ensureDefaultKeys()

Ensures the default keys.

getBBox()

Get the BBox value or rectangle.

Parameters
$asRect : boolean
 

getCanvas()

Get the canvas for this form XObject.

getGroup()

Get a group attributes object.

getHeight()

public float SetaPDF_Core_XObject_Form::getHeight ( [ float $width = null ] )

Get the height of the XObject.

Parameters
$width : float

To get the height in relation to a width value keeping the aspect ratio

See

getIndirectObject()

Get the indirect object of this XObject.

Parameters
$document : SetaPDF_Core_Document|null
 

getMatrix()

public boolean|SetaPDF_Core_Geometry_Matrix|array SetaPDF_Core_XObject_Form::getMatrix ( [ boolean $asArray = false ] )

Get the form matrix.

Parameters
$asArray : boolean

Defines whether the matrix be returned as an array or as a matrix instance.

getObject()

Get the indirect object of this XObject.

getResourceType()

public string SetaPDF_Core_XObject::getResourceType ( void )

Get the resource type for external objects.

See

getStreamProxy()

getWidth()

public float SetaPDF_Core_XObject_Form::getWidth ( [ float $height = null ] )

Get the width of the XObject.

Parameters
$height : float

To get the width in relation to a height value keeping the aspect ratio

See

setGroup()

Set the group attributes object.

Parameters
$group : false|SetaPDF_Core_TransparencyGroup
 
Exceptions

Throws InvalidArgumentException

setMatrix()

Set the form matrix.

Parameters
$matrix : int[]|SetaPDF_Core_Geometry_Matrix

An array of six numbers or a matrix instance.