Page 1 of 1

Fallback font applied too far in PDF output

Posted: Tue Nov 29, 2022 3:36 pm
by s_g
Hi,

I'm encountering a problem with using fallback fonts for Unicode glyps not contained in the main font. In the PDF output produced, not only is the direct glyph “⦗” (U+2997) rendered in the fallback font (marked BLUE in the screenshot below), but also the following characters (marked RED in the screenshot below) use the fallback font, until a whitespace character is encountered.

I'm applying the default font rules, is this a known problem or am I overlooking something here? I tried giving different font-family rules and fallback font options, but the problem persists.

I would be happy about any suggestions or possible solutions.

font-fallback-pdf.png

Re: Fallback font applied too far in PDF output

Posted: Tue Nov 29, 2022 4:19 pm
by julien_lacour
Hello,

What PDF scenario are you using? DITA Map PDF - based on HTML5 & CSS or DITA Map PDF - based on XSL-FO?

Regards,
Julien

Re: Fallback font applied too far in PDF output

Posted: Tue Nov 29, 2022 4:42 pm
by s_g
We are using the HTML+CSS based workflow, where we generate an intermediate HTML5 file via XSLT and then have custom CSS rules for the PDF generation process.

Re: Fallback font applied too far in PDF output

Posted: Tue Nov 29, 2022 5:01 pm
by julien_lacour
Hello,

We are aware of this issue and I already added your vote to it.
As a workaround you can add a Zero Width Space (​) character after the ⦗ character.

Regards,
Julien

Re: Fallback font applied too far in PDF output

Posted: Tue Nov 29, 2022 5:09 pm
by s_g
I tested your workaround and it works, thank you for your quick and helpful response!