src/solaris/classes/sun/awt/X11FontManager.java

Print this page




 698             fontConfigDirs = getFontConfiguration().getAWTFontPathSet();
 699             if (FontUtilities.debugFonts() && fontConfigDirs != null) {
 700                 String[] names = fontConfigDirs.toArray(new String[0]);
 701                 for (int i=0;i<names.length;i++) {
 702                     FontUtilities.getLogger().info("awtfontpath : " + names[i]);
 703                 }
 704             }
 705         }
 706     }
 707 
 708     @Override
 709     protected void registerPlatformFontsUsedByFontConfiguration() {
 710         // Lazily initialize fontConfigDirs.
 711         getPlatformFontPathFromFontConfig();
 712         if (fontConfigDirs == null) {
 713             return;
 714         }
 715         if (FontUtilities.isLinux) {
 716             fontConfigDirs.add(jreLibDirName+File.separator+"oblique-fonts");
 717         }
 718         fontdirs = (String[])fontConfigDirs.toArray(new String[0]);
 719     }
 720 
 721     // Implements SunGraphicsEnvironment.createFontConfiguration.
 722     protected FontConfiguration createFontConfiguration() {
 723         /* The logic here decides whether to use a preconfigured
 724          * fontconfig.properties file, or synthesise one using platform APIs.
 725          * On Solaris (as opposed to OpenSolaris) we try to use the
 726          * pre-configured ones, but if the files it specifies are missing
 727          * we fail-safe to synthesising one. This might happen if Solaris
 728          * changes its fonts.
 729          * For OpenSolaris I don't expect us to ever create fontconfig files,
 730          * so it will always synthesise. Note that if we misidentify
 731          * OpenSolaris as Solaris, then the test for the presence of
 732          * Solaris-only font files will correct this.
 733          * For Linux we require an exact match of distro and version to
 734          * use the preconfigured file, and also that it points to
 735          * existent fonts.
 736          * If synthesising fails, we fall back to any preconfigured file
 737          * and do the best we can. For the commercial JDK this will be
 738          * fine as it includes the Lucida fonts. OpenJDK should not hit




 698             fontConfigDirs = getFontConfiguration().getAWTFontPathSet();
 699             if (FontUtilities.debugFonts() && fontConfigDirs != null) {
 700                 String[] names = fontConfigDirs.toArray(new String[0]);
 701                 for (int i=0;i<names.length;i++) {
 702                     FontUtilities.getLogger().info("awtfontpath : " + names[i]);
 703                 }
 704             }
 705         }
 706     }
 707 
 708     @Override
 709     protected void registerPlatformFontsUsedByFontConfiguration() {
 710         // Lazily initialize fontConfigDirs.
 711         getPlatformFontPathFromFontConfig();
 712         if (fontConfigDirs == null) {
 713             return;
 714         }
 715         if (FontUtilities.isLinux) {
 716             fontConfigDirs.add(jreLibDirName+File.separator+"oblique-fonts");
 717         }
 718         fontdirs = fontConfigDirs.toArray(new String[0]);
 719     }
 720 
 721     // Implements SunGraphicsEnvironment.createFontConfiguration.
 722     protected FontConfiguration createFontConfiguration() {
 723         /* The logic here decides whether to use a preconfigured
 724          * fontconfig.properties file, or synthesise one using platform APIs.
 725          * On Solaris (as opposed to OpenSolaris) we try to use the
 726          * pre-configured ones, but if the files it specifies are missing
 727          * we fail-safe to synthesising one. This might happen if Solaris
 728          * changes its fonts.
 729          * For OpenSolaris I don't expect us to ever create fontconfig files,
 730          * so it will always synthesise. Note that if we misidentify
 731          * OpenSolaris as Solaris, then the test for the presence of
 732          * Solaris-only font files will correct this.
 733          * For Linux we require an exact match of distro and version to
 734          * use the preconfigured file, and also that it points to
 735          * existent fonts.
 736          * If synthesising fails, we fall back to any preconfigured file
 737          * and do the best we can. For the commercial JDK this will be
 738          * fine as it includes the Lucida fonts. OpenJDK should not hit