--- old/src/share/classes/sun/font/FontScaler.java 2014-02-04 23:35:31.000000000 -0800 +++ new/src/share/classes/sun/font/FontScaler.java 2014-02-04 23:35:31.000000000 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2014, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -82,23 +82,24 @@ public abstract class FontScaler implements DisposerRecord { private static FontScaler nullScaler = null; - private static Constructor scalerConstructor = null; + private static Constructor scalerConstructor = null; //Find preferred font scaler // //NB: we can allow property based preferences // (theoretically logic can be font type specific) static { - Class scalerClass = null; - Class arglst[] = new Class[] {Font2D.class, int.class, + Class scalerClass = null; + Class[] arglst = new Class[] {Font2D.class, int.class, boolean.class, int.class}; try { - if (FontUtilities.isOpenJDK) { - scalerClass = Class.forName("sun.font.FreetypeFontScaler"); - } else { - scalerClass = Class.forName("sun.font.T2KFontScaler"); - } + @SuppressWarnings("unchecked") + Class tmp = (Class) + (FontUtilities.isOpenJDK? + Class.forName("sun.font.FreetypeFontScaler"): + Class.forName("sun.font.T2KFontScaler")); + scalerClass = tmp; } catch (ClassNotFoundException e) { scalerClass = NullFontScaler.class; }