|
Duplicate :
|
This program below incorrectly prints false since JDK 6 b33 in April 2005 :
import java.awt.Font;
public class FNE {
public static void main(String[] args) throws Exception {
Font f1 = new Font("Lucida Sans", Font.PLAIN, 12);
Font cf1 = f1.deriveFont(Font.PLAIN, 12f);
f1.getAttributes();
//cf1.getAttributes();
System.out.println("equal="+f1.equals(cf1));
}
}
|