summaryrefslogtreecommitdiff
path: root/java/awt
diff options
context:
space:
mode:
Diffstat (limited to 'java/awt')
-rw-r--r--java/awt/Component.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/java/awt/Component.java b/java/awt/Component.java
index ac045d5d3..7f2cbb423 100644
--- a/java/awt/Component.java
+++ b/java/awt/Component.java
@@ -1198,7 +1198,12 @@ public abstract class Component
if (p != null)
f = p.getFontImpl();
else
- f = new Font("Dialog", Font.PLAIN, 12);
+ {
+ // It is important to return null here and not some kind of default
+ // font, otherwise the Swing UI would not install its fonts because
+ // it keeps non-UIResource fonts.
+ f = null;
+ }
}
return f;
}