Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8236451

Incorrect GlyphVector layout for a rotated font.

    Details

    • Type: Bug
    • Status: Open
    • Priority: P4
    • Resolution: Unresolved
    • Affects Version/s: 9, 11, 14, 15
    • Fix Version/s: 15
    • Component/s: client-libs
    • Labels:
    • Subcomponent:
      2d

      Description

      If you create a font with a rotation transform (not a transform on the graphics)
      and then call Font.layoutGlyphVector(..) the result is drawn horizontally - losing the rotation of the baseline, even though the glyph images are rotated.
      A test program demonstrating this is provided and shows that it does not
      affect TextLayout - only - a directly laid out GlyphVector.
      I think this is due to the different expectations of the two APIs as to the result of native layout.
      Also this occurs starting with JDK 9 and works fine in that release if I specify -Dsun.font.layoutengine=icu, so is a regression in the harfbuzz code.

      A minor note : the test program also failed on 8u on macos .. but worked (with ICU) on 9 so there was presumably a different macos bug fixed in 9.

      Also, another note: I discovered this issue whilst testing a fix for
      https://bugs.openjdk.java.net/browse/JDK-8224109

        Attachments

          Activity

            People

            • Assignee:
              prr Philip Race
              Reporter:
              prr Philip Race
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: