src/solaris/classes/sun/font/NativeFont.java
Print this page
rev 1297 : [mq]: fontmanager.patch
@@ -240,11 +240,12 @@
if (isBitmapDelegate) {
/* we are a delegate */
mapper = new NativeGlyphMapper(this);
} else {
/* we need to delegate */
- delegateFont = FontManager.getDefaultPhysicalFont();
+ SunFontManager fm = SunFontManager.getInstance();
+ delegateFont = fm.getDefaultPhysicalFont();
mapper = delegateFont.getMapper();
}
}
return mapper;
}
@@ -252,11 +253,12 @@
FontStrike createStrike(FontStrikeDesc desc) {
if (isBitmapDelegate) {
return new NativeStrike(this, desc);
} else {
if (delegateFont == null) {
- delegateFont = FontManager.getDefaultPhysicalFont();
+ SunFontManager fm = SunFontManager.getInstance();
+ delegateFont = fm.getDefaultPhysicalFont();
}
/* If no FileFont's are found, delegate font may be
* a NativeFont, so we need to avoid recursing here.
*/
if (delegateFont instanceof NativeFont) {
@@ -312,11 +314,12 @@
return numGlyphs;
}
PhysicalFont getDelegateFont() {
if (delegateFont == null) {
- delegateFont = FontManager.getDefaultPhysicalFont();
+ SunFontManager fm = SunFontManager.getInstance();
+ delegateFont = fm.getDefaultPhysicalFont();
}
return delegateFont;
}
/* Specify that the dpi is 72x72, as this corresponds to JDK's