## PDF::API2::Page

Subclassed from PDF::API2::PDF::Pages

$page = PDF::API2::Page->new $pdf, $parent, $index

Returns a page object (called from $pdf->page).

$page = PDF::API2::Page->coerce $pdf, $pdfpage

Returns a page object converted from $pdfpage (called from $pdf->openpage).

$page->update

Marks a page to be updated (by $pdf->update).

$page->mediabox $w, $h
$page->mediabox $llx, $lly, $urx, $ury
$page->mediabox $alias

Sets the mediabox. This method supports the following aliases: '4A', '2A', 'A0', 'A1', 'A2', 'A3', 'A4', 'A5', 'A6', '4B', '2B', 'B0', 'B1', 'B2', 'B3', 'B4', 'B5', 'B6', 'LETTER', 'BROADSHEET', 'LEDGER', 'TABLOID', 'LEGAL', 'EXECUTIVE', and '36X36'.

$page->cropbox $w, $h
$page->cropbox $llx, $lly, $urx, $ury
$page->cropbox $alias

Sets the cropbox. This method supports the same aliases as mediabox.

$page->bleedbox $w, $h
$page->bleedbox $llx, $lly, $urx, $ury
$page->bleedbox $alias

Sets the bleedbox. This method supports the same aliases as mediabox.

$page->trimbox $w, $h
$page->trimbox $llx, $lly, $urx, $ury

Sets the trimbox. This method supports the same aliases as mediabox.

$page->artbox $w, $h
$page->artbox $llx, $lly, $urx, $ury
$page->artbox $alias

Sets the artbox. This method supports the same aliases as mediabox.

$gfx = $page->gfx

Returns a graphics content object.

$txt = $page->text

Returns a text content object.

$hyb = $page->hybrid

Returns a hybrid content object.

$ant = $page->annotation

Returns a annotation object.

$page->resource $type, $key, $obj

Adds a resource to the page-inheritance tree.

Example:

    	$co->resource('Font',$fontkey,$fontobj);
    	$co->resource('XObject',$imagekey,$imageobj);
    	$co->resource('Shading',$shadekey,$shadeobj);
    	$co->resource('ColorSpace',$spacekey,$speceobj);

Note: You only have to add the required resources, if they are NOT handled by the *font*, *image*, *shade* or *space* methods.

# AUTHOR

alfred reibenschuh