提交 b946903d 编写于 作者: P prr

6989370: Windows platform fonts may be incorrectly marked as ineligible for the native rasteriser

Reviewed-by: igor, jgodinez
上级 1c67e52e
...@@ -1576,7 +1576,7 @@ public abstract class SunFontManager implements FontSupport, FontManagerForSGE { ...@@ -1576,7 +1576,7 @@ public abstract class SunFontManager implements FontSupport, FontManagerForSGE {
.info("Trying to resolve file " + fullPath); .info("Trying to resolve file " + fullPath);
} }
do { do {
ttf = new TrueTypeFont(fullPath, null, fn++, true); ttf = new TrueTypeFont(fullPath, null, fn++, false);
// prefer the font's locale name. // prefer the font's locale name.
String fontName = ttf.getFontName(l).toLowerCase(); String fontName = ttf.getFontName(l).toLowerCase();
if (unmappedFonts.contains(fontName)) { if (unmappedFonts.contains(fontName)) {
......
...@@ -63,7 +63,7 @@ public class Win32FontManager extends SunFontManager { ...@@ -63,7 +63,7 @@ public class Win32FontManager extends SunFontManager {
if (eudcFile != null) { if (eudcFile != null) {
try { try {
eudcFont = new TrueTypeFont(eudcFile, null, 0, eudcFont = new TrueTypeFont(eudcFile, null, 0,
true); false);
} catch (FontFormatException e) { } catch (FontFormatException e) {
} }
} }
...@@ -137,6 +137,7 @@ public class Win32FontManager extends SunFontManager { ...@@ -137,6 +137,7 @@ public class Win32FontManager extends SunFontManager {
try { try {
while (!found && parser.hasMoreTokens()) { while (!found && parser.hasMoreTokens()) {
String newPath = parser.nextToken(); String newPath = parser.nextToken();
boolean isJREFont = newPath.equals(jreFontDirName);
File theFile = new File(newPath, fontFileName); File theFile = new File(newPath, fontFileName);
if (theFile.canRead()) { if (theFile.canRead()) {
found = true; found = true;
...@@ -144,11 +145,11 @@ public class Win32FontManager extends SunFontManager { ...@@ -144,11 +145,11 @@ public class Win32FontManager extends SunFontManager {
if (defer) { if (defer) {
registerDeferredFont(fontFileName, path, registerDeferredFont(fontFileName, path,
nativeNames, nativeNames,
fontFormat, true, fontFormat, isJREFont,
fontRank); fontRank);
} else { } else {
registerFontFile(path, nativeNames, registerFontFile(path, nativeNames,
fontFormat, true, fontFormat, isJREFont,
fontRank); fontRank);
} }
break; break;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册