-
def test_subfont0(): |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
If you do things like the above, you leave your fate in the hands of MuPDF's automatic font selection algorithm. If I stood in your shoes I would exert some influence and specify at least a font family to choose from, e.g. "sans-serif". So with this text, you will end up with 3 fonts automatically identified by MuPDF. One of them, because of the 2 ideographic punctuations, is very large: (6, 'otf', 'Type0', 'Noto Serif Regular', 'F0', 'Identity-H', 24)
(12, 'cid', 'Type0', 'Charis SIL Regular', 'F1', 'Identity-H', 24)
(18, 'otf', 'Type0', 'Source Han Serif TC Regular', 'F2', 'Identity-H', 24) If you do (6, 'cid', 'Type0', 'Nimbus Sans Regular', 'F0', 'Identity-H', 18)
(12, 'otf', 'Type0', 'Source Han Serif TC Regular', 'F1', 'Identity-H', 18) If you replace the punctuation by normal comma and colon, only one front will be used (Nimbus Sans Regular). |
Beta Was this translation helpful? Give feedback.
If you do things like the above, you leave your fate in the hands of MuPDF's automatic font selection algorithm. If I stood in your shoes I would exert some influence and specify at least a font family to choose from, e.g. "sans-serif".
Other than that, why did you take "、" instead of a normal comma? That character, has the Unicode 0x3001 (12289, 'ideographiccomma') and is far outside the Extended Latin character set.
The same is true for "。" (0x3002, 12290, 'ideographicperiod'). Why not a normal colon?
Both characters only appear to be followed by a space, but there is no space, so crazy line breaks (in the middle of a word) can easily occur.
So with this text, you will end up with 3 fon…