public class FontKey
extends java.lang.Object
Constructor and Description |
---|
FontKey(java.lang.String name,
boolean bold,
boolean italic)
Creates a new font key.
|
Modifier and Type | Method and Description |
---|---|
static FontKey |
createFontKey(java.awt.Font f)
Creates a new key for a given font.
|
boolean |
equals(java.lang.Object obj)
Tests this key for equality with an arbitrary object.
|
int |
hashCode()
Returns a hash code for this instance.
|
java.lang.String |
toString()
Returns a string representation of this instance, primarily for
debugging purposes.
|
public FontKey(java.lang.String name, boolean bold, boolean italic)
name
- the name.bold
- the bold flag.italic
- the italic flag.createFontKey(java.awt.Font)
public static FontKey createFontKey(java.awt.Font f)
f
- the font (null
not permitted).public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
obj
- the object to test against (null
permitted).public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object