8078382: Wrong glyph is displayed for a derived font
authorbae
Thu, 02 Jun 2016 15:36:15 +0300
changeset 39024 9c63f12138b7
parent 39023 8b91cb9a723e
child 39025 bbc996c042d3
8078382: Wrong glyph is displayed for a derived font Reviewed-by: prr, serb
jdk/src/java.desktop/share/classes/sun/font/FontFamily.java
--- a/jdk/src/java.desktop/share/classes/sun/font/FontFamily.java	Thu Jun 02 15:20:31 2016 +0530
+++ b/jdk/src/java.desktop/share/classes/sun/font/FontFamily.java	Thu Jun 02 15:36:15 2016 +0300
@@ -335,10 +335,10 @@
         case Font.BOLD|Font.ITALIC:
             if (bolditalic != null) {
                 return bolditalic;
+            } else if (bold != null && bold.canDoStyle(style)) {
+                return bold;
             } else if (italic != null && italic.canDoStyle(style)) {
                     return italic;
-            } else if (bold != null && bold.canDoStyle(style)) {
-                    return italic;
             } else if (plain != null && plain.canDoStyle(style)) {
                     return plain;
             } else {