Table of contents
Namespace: Com\Tecnick\Pdf\Page
abstract class Settings extends Box
Extends: Box
Source: src/Settings.php:50
Constants
EPS
Epsilon precision used to compare floating point values.
public const EPS = 0.0001
Source: src/Settings.php:55
MAX_COLUMNS
Maximum number of equal vertical columns a page can be split into.
public const MAX_COLUMNS = 1000
Source: src/Settings.php:72
MAX_PAGE_LABEL_START
Largest first number of a page label range: the largest PDF integer (ISO 32000-1, Annex C).
public const MAX_PAGE_LABEL_START = 2147483647
Source: src/Settings.php:61
PAGE_LABEL_STYLES
Page label numbering styles (ISO 32000-1, 12.4.2): decimal arabic, upper and lower case roman, upper and lower case letters, and ’’ for no numeric part.
public const PAGE_LABEL_STYLES = ['D', 'R', 'r', 'A', 'a', '']
Source: src/Settings.php:67
PAGE_NUM
Alias for page number.
public const PAGE_NUM = '~#PN'
Source: src/Settings.php:86
PAGE_TOT
Alias for total number of pages in a group.
public const PAGE_TOT = '~#PT'
Source: src/Settings.php:79
Methods
getPageID()
Return the current page ID.
public getPageID(): int
Returns: int: Page ID.
Source: src/Settings.php:186
sanitizeAnnotRefs()
Sanitize or set the annotation references.
public sanitizeAnnotRefs(PageInputData &$data): void
Parameters:
$data(PageInputData): Page data.
Source: src/Settings.php:321
sanitizeBoxData()
Sanitize or set the page boxes containing the page boundaries.
Every entry of PageInputData[‘box’] is optional and is completed first.
public sanitizeBoxData(PageInputData &$data): void
Parameters:
$data(PageInputData): Page data.
Throws:
Source: src/Settings.php:796
sanitizeContent()
Sanitize or set the page content.
public sanitizeContent(PageInputData &$data): void
Parameters:
$data(PageInputData): Page data.
Source: src/Settings.php:301
sanitizeGroup()
Sanitize or set the page group.
public sanitizeGroup(PageInputData &$data): void
Parameters:
$data(PageInputData): Page data.
Source: src/Settings.php:291
sanitizeLabel()
Sanitize the page label. A missing or empty label is removed.
public sanitizeLabel(PageInputData &$data): void
Parameters:
$data(PageInputData): Page data.
Throws:
Source: src/Settings.php:210
sanitizeMargins()
Sanitize or set the page margins.
public sanitizeMargins(PageInputData &$data): void
Parameters:
$data(PageInputData): Page data.
Throws:
Source: src/Settings.php:490
sanitizePageFormat()
Sanitize or set the page format.
The pseudo-format ‘MediaBox’ means that the page size is taken from the MediaBox: it is left untouched here and resolved by sanitizeBoxData(), which then re-enters this method with the box-derived dimensions and a cleared format.
public sanitizePageFormat(PageInputData &$data): void
Parameters:
$data(PageInputData): Page data.
Throws:
Source: src/Settings.php:930
sanitizePageNumber()
Sanitize or set the page number.
public sanitizePageNumber(PageInputData &$data): void
Parameters:
$data(PageInputData): Page data.
Source: src/Settings.php:196
sanitizeRegions()
Sanitize or set the page regions (columns).
public sanitizeRegions(PageInputData &$data): void
Parameters:
$data(PageInputData): Page data.
Source: src/Settings.php:677
sanitizeRotation()
Sanitize or set the page rotation.
The number of degrees by which the page shall be rotated clockwise when displayed or printed. The value shall be a multiple of 90; it is normalized to the [0, 360) range.
public sanitizeRotation(PageInputData &$data): void
Parameters:
$data(PageInputData): Page data.
Source: src/Settings.php:335
sanitizeTime()
Sanitize or set the page modification time.
A missing time is set to the default page time, or to the current time when no default is set. Negative values are set to 0.
public sanitizeTime(PageInputData &$data): void
Parameters:
$data(PageInputData): Page data.
Source: src/Settings.php:281
sanitizeTransitions()
Sanitize or set the page transitions.
public sanitizeTransitions(PageInputData &$data): void
Parameters:
$data(PageInputData): Page data.
Source: src/Settings.php:368
sanitizeZoom()
Sanitize or set the page preferred zoom (magnification) factor.
The factor is a magnification, so any non-positive value falls back to 1.0.
public sanitizeZoom(PageInputData &$data): void
Parameters:
$data(PageInputData): Page data.
Source: src/Settings.php:354
Inherited members
From Box
- BOX: Page box names.
- setBox(): Set page boundaries.
- setPageBoxes(): Initialize page boxes.
- swapCoordinates(): Swap X and Y coordinates of page boxes (change page boxes orientation).
From Format
- FORMAT: Array of page formats (width, height).
- UNITRATIO: Array of conversion ratios relative to points.
- convertPoints(): Convert Points to another unit.
- getPageFormatSize(): Get page dimensions.
- getPageOrientation(): Returns the page orientation.
- getPageOrientedSize(): Returns the page dimensions oriented as specified.
- getUnitRatio(): Get the unit ratio for the specified unit of measure.
From Mode
- getDisplay(): Get the canonical page display mode.
- getLayout(): Get the canonical page layout name.