OpenXML: Incorrect ctype values

Issue #703 resolved
Chase Tingley created an issue

The OpenXML will sometimes produce incorrect ctype values for OpenXML styled text.

Testcase attached. To reproduce:

tikal.sh -fc okf_openxml -codeattrs -x italics2.docx

The second sentence in the XLIFF will have <g> tags that include italics and bold in the ctype string. This is incorrect as seen if you open the document for editing in Word/LibreOffice.

It looks like the <w:iCS/> and <w:bCS/> tags are being treated as active italics/bold styling when they should not be.

Comments (4)

  1. Chase Tingley reporter

    Fix issue #703 - Don't emit bold/italic ctype values for CS styles

    OpenXML supports a separate set of formatting properties to indicate
    whether bold/italics should be applied to complex script characters
    in the run. We had previously been translating these properties into
    regular bold/italic ctype values. However, this produces situations
    where our XLIFF shows text as being bold/italicized, but the
    document itself does not.  This is because the bCS/iCS properties
    in the openxml are sometimes spuriousy set on runs that don't
    contain complex script characters.
    

    → <<cset 6a80b6406e5e>>

  2. Chase Tingley reporter

    An additional note here. We may eventually want to support exposing iCS/bCS as part of ctype, but we shouldn't do it by just translating it to regular italic/bold as we had before. It's a different property that is applied to different character ranges, so it should be supported separately.

  3. Log in to comment