OpenXML: double-quotes in translatable attribute values aren't escaped on merge

Issue #679 resolved
Chase Tingley created an issue

I think this may affect a few cases, but the easiest one to see is with watermarks, for example with the attached file.

To reproduce:

  • Extract the attached DOCX to XLIFF
  • Translate the string DRAFT as DRAFT" (ie, add a double quote at the end of the string)
  • Merge the XLIFF back to DOCX

The merged file won't open in Word because the word/header2.xml file has been corrupted:

<v:textpath style="font-family:&quot;Calibri&quot;;font-size:1pt" string="DRAFT""/>

The embedded " needs to be written out as an entity instead.

Comments (3)

  1. Log in to comment