All Packages Class Hierarchy This Package Previous Next Index
Class java.awt.Font
java.lang.Object
|
+----java.awt.Font
- public class Font
- extends Object
- implements Serializable
A class that produces font objects.
-
BOLD
- The bold style constant.
-
ITALIC
- The italicized style constant.
-
name
-
The logical name of this font.
-
PLAIN
- The plain style constant.
-
size
-
The point size of this font.
-
style
-
The style of the font.
-
Font(String, int, int)
- Creates a new font with the specified name, style and point size.
-
decode(String)
- Gets the specified font using the name passed in.
-
equals(Object)
- Compares this object to the specifed object.
-
getFamily()
- Gets the platform specific family name of the font.
-
getFont(String)
- Gets a font from the system properties list.
-
getFont(String, Font)
- Gets the specified font from the system properties list.
-
getName()
- Gets the logical name of the font.
-
getPeer()
- Gets the peer of the font.
-
getSize()
- Gets the point size of the font.
-
getStyle()
- Gets the style of the font.
-
hashCode()
- Returns a hashcode for this font.
-
isBold()
- Returns true if the font is bold.
-
isItalic()
- Returns true if the font is italic.
-
isPlain()
- Returns true if the font is plain.
-
toString()
-
Converts this object to a String representation.
PLAIN
Properties Public Constant
PLAIN=int
- The plain style constant. This can be combined with the other style
constants for mixed styles.
BOLD
Properties Public Constant
BOLD=int
- The bold style constant. This can be combined with the other style
constants for mixed styles.
ITALIC
Properties Public Constant
ITALIC=int
- The italicized style constant. This can be combined with the other
style constants for mixed styles.
name
Properties Inheritable
name=String
- The logical name of this font.
style
Properties Inheritable
style=int
- The style of the font. This is the sum of the
constants PLAIN, BOLD, or ITALIC.
size
Properties Inheritable
size=int
- The point size of this font.
Font
method Font(name=String, -
style=int, -
size=int) public
- Creates a new font with the specified name, style and point size.
- Parameters:
- name - the font name
- style - the constant style used
- size - the point size of the font
- See Also:
- getFontList
getPeer
method getPeer() returns FontPeer public
- Gets the peer of the font.
getFamily
method getFamily() returns String public
- Gets the platform specific family name of the font.
Use getName to get the logical name of the font.
- See Also:
- getName
getName
method getName() returns String public
- Gets the logical name of the font.
- See Also:
- getFamily
getStyle
method getStyle() returns int public
- Gets the style of the font.
- See Also:
- isPlain, isBold, isItalic
getSize
method getSize() returns int public
- Gets the point size of the font.
isPlain
method isPlain() returns boolean public
- Returns true if the font is plain.
- See Also:
- getStyle
isBold
method isBold() returns boolean public
- Returns true if the font is bold.
- See Also:
- getStyle
isItalic
method isItalic() returns boolean public
- Returns true if the font is italic.
- See Also:
- getStyle
getFont
method getFont(nm=String) returns Font public static
- Gets a font from the system properties list.
- Parameters:
- nm - the property name
decode
method decode(str=String) returns Font public static
- Gets the specified font using the name passed in.
- Parameters:
- str - the name
getFont
method getFont(nm=String, -
font=Font) returns Font public static
- Gets the specified font from the system properties list.
- Parameters:
- nm - the property name
- font - a default font to return if property 'nm' is not defined
hashCode
method hashCode() returns int public
- Returns a hashcode for this font.
- Overrides:
- hashCode in class Object
equals
method equals(obj=Object) returns boolean public
- Compares this object to the specifed object.
- Parameters:
- obj - the object to compare with
- Returns:
- true if the objects are the same; false otherwise.
- Overrides:
- equals in class Object
toString
method toString() returns String public
- Converts this object to a String representation.
- Overrides:
- toString in class Object
All Packages Class Hierarchy This Package Previous Next Index