JDK-6223022 : '8' in 11pt Tahoma font is not rendered properly
  • Type: Bug
  • Component: client-libs
  • Sub-Component: 2d
  • Affected Version: 1.4.0,1.4.2,6
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: generic,windows_xp
  • CPU: generic,x86
  • Submitted: 2005-01-28
  • Updated: 2011-03-08
  • Resolved: 2011-03-08
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 6 JDK 7
6u10Fixed 7 b28Fixed
Related Reports
Duplicate :  
Relates :  
Relates :  
Relates :  
Description
FULL PRODUCT VERSION :
java version "1.4.2_05"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_05-b04)
Java HotSpot(TM) Client VM (build 1.4.2_05-b04, mixed mode)

ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows XP [Version 5.1.2600]


A DESCRIPTION OF THE PROBLEM :
The character '8' is not rendered properly when using Tahoma plain 11 pt font (corresponds to Windows "native" font Tahoma 8).


REPRODUCIBILITY :
This bug can be reproduced always.

---------- BEGIN SOURCE ----------
import java.awt.*;
import javax.swing.*;

public class TahomaFontTest extends JFrame
{
   public TahomaFontTest()
   {
      JTextField tf = new JTextField("88888");
      tf.setFont(new Font("Tahoma", Font.PLAIN, 11));
      getContentPane().add(tf);
      pack();
      setVisible(true);
   }
   
   public static void main(String[] args)
   {
      try
      {
         UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
      }
      catch(Exception e)
      {
         e.printStackTrace();
      }
      new TahomaFontTest();
   }
}

---------- END SOURCE ----------

CUSTOMER SUBMITTED WORKAROUND :
Use JRE 1.3.x :(
###@###.### 2005-1-28 19:09:19 GMT

Comments
EVALUATION Fix for this problem will also include fix for the 6320262.
15-10-2007

EVALUATION The problem is cause by using scaled outlines instead of unscaled outlines while processing IP hinting instruction. Being theoretically equivalent in reality they are not because of limitated precision of fixed point math we use. Difference in result of calculation is very small but in this particular case it has visible manifistation. Reverting to usage of original outlines helps to resolve this issue and some other problems as well. In particular y from the Courier New font seems more clear in LCD mode.
11-10-2007

EVALUATION I have filed this separately than 4924220 which is specifically about problems with the Microsoft Sans Serif font, whereas this is a difference in the Tahoma font. It seems best to track this differently unless its confirmed that this issue has the same underlying cause as some of the issues in Microsoft Sans Serif. The difference I see is quite small. We turn on on extra pixel - the one identified with "+", so there is some minor asymmetry in the glyph. XXX X X X X XXX X +X X X XXX ###@###.### 2005-1-28 19:10:35 GMT
28-01-2005