Feb-12-2023, 06:39 PM
I have worked around the issue for now with an ugly hack
def removeMultipleFonts(self): html = self.editor.document().toHtml() htmlTransformed = re.sub(r"(font-family:)('.+'),('.+')", r'\1\3', html) self.editor.document().setHtml(htmlTransformed)Is seems to resolve the issue. I invoke this on changing font and saving the file.