---
name: "PDF::Builder::Resource::XObject::Form"
section: "3pm"
platform: "linux"
package: "perl-pdf-builder"
version: "3.028-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/PDF::Builder::Resource::XObject::Form"
---

# PDF::Builder::Resource::XObject::Form(3pm)

Base class for external form objects Inherits from PDF::Builder::Resource::XObject

## NAME

PDF::Builder::Resource::XObject::Form - Base class for external form objects

Inherits from PDF::Builder::Resource::XObject

## METHODS

### new

```
    $form = PDF::Builder::Resource::XObject::Form->new($pdf)
```

Creates a form resource.

### bbox

```
    ($llx, $lly, $urx, $ury) = $form->bbox($llx, $lly, $urx, $ury)
```

Get or set the coordinates of the form object's bounding box.

### resource

```
    $resource = $form->resource($type, $key)
    $form->resource($type, $key, $object, $force)
```

Get or add a resource required by the form's contents, such as a Font, XObject, ColorSpace, etc.

By default, an existing `$key` will not be overwritten. Set `$force` to override this behavior.
