https://bugs.documentfoundation.org/show_bug.cgi?id=163151

            Bug ID: 163151
           Summary: vertical cell orientation: Chinese glyphs not
                    displayed as rotated
           Product: LibreOffice
           Version: Inherited From OOo
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: Writer
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected]

Created attachment 196679
  --> https://bugs.documentfoundation.org/attachment.cgi?id=196679&action=edit
test_chinese_vertical.doc: Latin characters (A B C) are displayed rotated, but
not the Chinese characters

In test_chinese_vertical.doc, the table properties are set so that the "text
flow" has a "text orientation" of "Vertical (top to bottom)". The effect is
that the characters should be rotated 90 degrees clockwise. While A, B, and C
are rotated, the Chinese glyphs are not.

OOo 3.3 already looks like this.

There is code specifically intended to address this (or a similar) situation in
vcl/source/gdi/CommonSalLayout.cxx's GenericSalLayout::LayoutText.

    // Characters with U and Tu vertical orientation should
    // be shaped in vertical direction. But characters
    // with Tr should be shaped in vertical direction
    // only if they have vertical alternates, otherwise
    // they should be shaped in horizontal direction
    // and then rotated.
    // See http://unicode.org/reports/tr50/#vo
    if (aVo == U_VO_UPRIGHT || aVo == U_VO_TRANSFORMED_UPRIGHT ||
       (aVo == U_VO_TRANSFORMED_ROTATED &&
            HasVerticalAlternate(aChar, aVariationSelector)))
    {
        aDirection = HB_DIRECTION_TTB;
    }

For this particular document, if we do NOT set the direction to
HB_DIRECTION_TTB, then it displays the way we want it to.

Or, if nGlyphFlags is not set to GlyphItemFlags::IS_VERTICAL, then the Chinese
characters remain rotated.

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to