classpath-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[cp-patches]: Patch: Font fix


From: Lillian Angel
Subject: [cp-patches]: Patch: Font fix
Date: Wed, 28 Sep 2005 09:56:05 -0400

This fix makes sure that the font is never set to null. It should be
the font set by any class, or the default font if none was set.

Component.getFont returns null if no font was set. It does not return
the default font. A UI delegate should install its default font on a
JComponent only if the existing font is null or implements UIResource.
if it does neither, then the font used in painting is the default.  

2005-09-28  Lillian Angel  <address@hidden>

        Fixes Bug #24077
        * gnu/java/awt/peer/gtk/GdkFontMetrics.java
        (GdkFontMetrics): Added a check for the font
        being null. Fixed a NPE.
        * gnu/java/awt/peer/gtk/GdkGraphics.java
        (GdkGraphics): Added check if the font is null.
        If it is, the font should be set to the default.
        (setFont): If font parameter is null, this.font should not
        be changed.
        * javax/swing/JPopupMenu.java:
        Fixed API documentation to say 'JDialog' rather than
        'JWindow'.

Attachment: fontFix.diff
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]