Table of contents
Namespace: Com\Tecnick\Pdf\Page
Backing type: string
File: PageBoxType.php line 37
Backed enum for the PDF page boundary box names. The backing value of each case matches an entry of Box::BOX validated by Box::setBox().
Tags
- since: 2026-07-17
- category: Library
- author: Nicola Asuni info@tecnick.com
- copyright: 2011-2026 Nicola Asuni - Tecnick.com LTD
- license: https://www.gnu.org/copyleft/lesser.html GNU-LGPL v3 (see LICENSE)
- link: https://github.com/tecnickcom/tc-lib-pdf-page
Cases
MediaBox
File: PageBoxType.php line 39
CropBox
File: PageBoxType.php line 41
BleedBox
File: PageBoxType.php line 43
TrimBox
File: PageBoxType.php line 45
ArtBox
File: PageBoxType.php line 47
Methods
fromLoose()
File: PageBoxType.php line 59
public static fromLoose(string|self $value) : self
Accepts the exact box name (as validated by Box::setBox) or an enum instance (returned unchanged). Unknown values throw.
Parameters
- $value : string|self: Page box name or enum case.
Tags
- throws: Exception if the value does not match a known page box.
Return values
self