AbstractPdf - ZendException font is not set #11743
Labels
Fixed in 2.2.x
The issue has been fixed in 2.2 release line
Issue: Clear Description
Gate 2 Passed. Manual verification of the issue description passed
Issue: Confirmed
Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed
Issue: Format is valid
Gate 1 Passed. Automatic verification of issue format passed
Issue: Ready for Work
Gate 4. Acknowledged. Issue is added to backlog and ready for development
Reproduced on 2.2.x
The issue has been reproduced on latest 2.2 release
Reproduced on 2.3.x
The issue has been reproduced on latest 2.3 release
Preconditions
Steps to reproduce
drawLineBlocks()
(my apologies for not providing a better example here - this came up during development of a custom module, which I am unable to include here)Expected result
Actual result
The issue is caused by lines 1034-1036 in /vendor/magento/module-sales/Model/Order/Pdf/AbstractPdf.php.
This new page is created after the font has been determined (lines 1008-1025) and set for the line to be written. Therefore, at the time line 1057 is reached (below), the font for the new page has not been set.
$page->drawText($part, $feed, $this->y - $top, 'UTF-8');
The solution would be to re-set the page's font after creating the new page.
The text was updated successfully, but these errors were encountered: