JDK-8230150 : Missing glyphs in AWT components due to lack of default CJK TrueType fonts in RHEL 8
  • Type: Bug
  • Component: client-libs
  • Sub-Component: 2d
  • Affected Version: 8u221
  • Priority: P3
  • Status: Closed
  • Resolution: Duplicate
  • Submitted: 2019-08-26
  • Updated: 2019-11-19
  • Resolved: 2019-09-26
Related Reports
Duplicate :  
Sub Tasks
JDK-8231772 :  
Description
Java 8 can't render Japanese characters on Red Hat Enterprise Linux 8.
The vlgothic-fonts package which was part of RHEL 7 is replaced with google-noto-sans-cjk-ttc-fonts package in RHEL 8. This seems to cause problems with Java 8.
Comments
The work to add support for CFF format fonts to Oracle JDK 8 is being tracked under JDK-8209672. JDK-8209672 is the extreme case where no other fonts are found which leads to ArrayIndexOutOfBoundsException.
06-11-2019

JDK 13 has no issues with CJK on RHEL 8. After comparing the fontconfig files for JDK 13 and JDK 8, I found the following differences: Fontconfig for 13 contains the following line: serif.0.0.file=/usr/share/fonts/google-noto-cjk/NotoSerifCJK-Regular.ttc That is the default font is a CFF format font. Java 8 does not accept fonts in CFF format (yet). So such a line is missing in fontconfig file for 8. Indeed, there are no references to fonts with .ttc extension in fontconfig for 8u221 whereas 13 contains 24 references to such fonts: fonts$ grep -c .ttc 1*/*.properties 1.8.0_221/fcinfo-...RedHat-8.0-ja.properties:0 13/fcinfo-...-RedHat-8.0-ja-JP.properties:24 The vlgothic-fonts package provided TrueType fonts to render CJK which were used by Java 8. Without this package, Java 8 has no font to render CJK text that's why the missing glyphs are seen.
26-09-2019