Block

HTML block boxes, vertical spacing and PDF/UA structure elements.

Table of contents

Namespace: Com\Tecnick\Pdf\HTML

trait Block

Source: src/HTML/Block.php:42

HTML block boxes, vertical spacing and PDF/UA structure elements.

Methods

setHtmlVSpace()

Set custom vertical spacing for HTML block tags.

Each tag entry has two positions: [0] = space added before the opening tag (top margin) [1] = space added after the closing tag (bottom margin)

Each position is an array with optional keys: ‘h’ => float (fixed height in user units) ’n’ => int (number of line-heights to add)

Example: $pdf->setHtmlVSpace([‘p’ => [[‘h’ => 0, ’n’ => 1], [‘h’ => 0, ’n’ => 0]]]);

public setHtmlVSpace(array<string,array<int,array{h?: float|int, n?: int}>> $tagvs): void

Parameters:

  • $tagvs (array<string,array<int,array{h?: float|int, n?: int}>>)

Source: src/HTML/Block.php:1010