TextHAlign

Backed enum for the horizontal alignment of text inside a cell: L (left), C (center), R (right) or J (justify).

Namespace: Com\Tecnick\Pdf

Backing type: string

File: TextHAlign.php line 35

Backed enum for the horizontal alignment of text inside a cell: L (left), C (center), R (right) or J (justify).

Tags

Cases

Left

File: TextHAlign.php line 37

Center

File: TextHAlign.php line 39

Right

File: TextHAlign.php line 41

Justify

File: TextHAlign.php line 43

Methods

fromLoose()

File: TextHAlign.php line 54

public static fromLoose(string|self $value) : self

Accepts L, C, R or J (case-insensitive, surrounding whitespace trimmed) or an enum instance (returned unchanged). Unknown values fall back to Left, matching the cell horizontal alignment default.

Parameters

  • $value : string|self: Horizontal alignment or enum case.

Return values

self