PDF: fix normalization of unicode combination characters

This commit is contained in:
Richard Schreiber
2023-06-28 10:34:17 +02:00
parent 714ef0d3b6
commit 104607d34e

View File

@@ -939,7 +939,7 @@ class Renderer:
# reportlab does not support unicode combination characters
# It's important we do this before we use ArabicReshaper
text = unicodedata.normalize("NFKC", text)
text = unicodedata.normalize("NFC", text)
# reportlab does not support RTL, ligature-heavy scripts like Arabic. Therefore, we use ArabicReshaper
# to resolve all ligatures and python-bidi to switch RTL texts.