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

Setting ANTIALIASING=ON when TEXT_ANTIALIASING is LCD_HRGB does not revalidate font info

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • 6
    • 6
    • client-libs
    • 2d
    • b39
    • 6
    • b63
    • generic
    • generic

      If the graphics AA hint is set, and the text AA hint is left at "default"
      the historical behaviour is for text AA to then follow the graphics AA hint.
      ie setting the graphics AA hint in this case causes the text hint state to be
      revalidated to follow the graphics hint state.

      When the graphics AA hint is set to ON, it installs new text loops which
      operate on a greyscale mask.
      But it does not invalidate the cached font/text info, and in the case
      where in mustang that text AA hint is already set for an LCD text mode,
      the subsequent text output is garbage.

      This bug shouldn't affect pre mustang apps as they don't specify LCD text, and where
      its used in JDK internally (Swing) the text hint is explicitly set/unset as needed
      so revalidation is happening anyway. Still its likely to be seen in some graphics
      apps that try to use the new LCD text mode, so we should fix it.

      The fix is a simple extra test that if the current text rendering is an
      LCD mode, we must revalidate it when the regular AA hint is updated.

      For the common cases this should become a non-issue once
      6263951:Java does not use fast AA text loops when regular AA hint is set
      is fixed, as the LCD loops will also be preserved.
      However even then there will be a need for invalidation until such time as
      all rendering modes can support LCD text data.

            prr Philip Race
            prr Philip Race
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: