I am using Dompdf 0.8.0 to create my PDF. In one page there are multiple fonts used. i.e. 2 font types are used for signatures and one is regular font.
But when we reach the signature fonts it changes all of the page fonts to signature fonts.
Please see attached image and underlined text. These marked text are signatures, the others are normal text. Note the behavior of changing fonts. Each signature has a different font family. And after the text has changed to the respective font family.
I tried these ways already:
- Used classes for signatures.
- Used fonts family in line in tag.
Used fonts in dompdf options:
$dompdf->set_option('defaultFont', 'dejavu sans');
Also tried with options:
$options = new Options();
$options->set('defaultFont', 'dejavu sans');