# HG changeset patch # User ssadetsky # Date 1473428236 -10800 # Node ID 726399082620ea3540bddaafca28351908894dfa # Parent d483612439250d13ce78749ea81d15abededeb64 8160054: The FileChooser didn't displayed large font with GTK LAF option. Reviewed-by: alexsch, serb diff -r d48361243925 -r 726399082620 jdk/src/java.desktop/share/classes/com/sun/java/swing/plaf/gtk/GTKLookAndFeel.java --- a/jdk/src/java.desktop/share/classes/com/sun/java/swing/plaf/gtk/GTKLookAndFeel.java Fri Sep 09 13:15:10 2016 +0530 +++ b/jdk/src/java.desktop/share/classes/com/sun/java/swing/plaf/gtk/GTKLookAndFeel.java Fri Sep 09 16:37:16 2016 +0300 @@ -504,7 +504,7 @@ public Object createValue(UIDefaults table) { GTKStyleFactory factory = (GTKStyleFactory)getStyleFactory(); GTKStyle style = (GTKStyle)factory.getStyle(null, region); - return style.getFontForState(null); + return style.getDefaultFont(); } } diff -r d48361243925 -r 726399082620 jdk/src/java.desktop/share/classes/com/sun/java/swing/plaf/gtk/GTKStyle.java --- a/jdk/src/java.desktop/share/classes/com/sun/java/swing/plaf/gtk/GTKStyle.java Fri Sep 09 13:15:10 2016 +0530 +++ b/jdk/src/java.desktop/share/classes/com/sun/java/swing/plaf/gtk/GTKStyle.java Fri Sep 09 16:37:16 2016 +0300 @@ -282,7 +282,17 @@ return getColorForState(context, type); } + Font getDefaultFont() { + return font; + } + protected Font getFontForState(SynthContext context) { + Font propFont = UIManager + .getFont(context.getRegion().getName() + ".font"); + if (propFont != null) { + // if font property got a value then return it + return propFont; + } return font; }