org.apache.fop.render.afp.fonts
Class BaseFont
java.lang.Object
org.apache.fop.render.afp.fonts.BaseFont
- All Implemented Interfaces:
- org.apache.fop.layout.FontMetric
- Direct Known Subclasses:
- OutlineFont, RasterFont
- public abstract class BaseFont
- extends java.lang.Object
- implements org.apache.fop.layout.FontMetric
All implemenations of AFP fonts should extend this base class,
the object implements the FontMetrics information.
Field Summary |
protected java.lang.String |
_name
The font name |
protected java.lang.String |
_style
The font style |
protected java.lang.String |
_weight
The font weight |
Constructor Summary |
BaseFont(java.lang.String name,
java.lang.String weight,
java.lang.String style)
Constructor for the base font requires the name, weight and style
attribute to be available as this forms the key to the font. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.apache.fop.layout.FontMetric |
getAscender, getCapHeight, getDescender, getFirstChar, getLastChar, getWidths, getXHeight, width |
_name
protected java.lang.String _name
- The font name
_weight
protected java.lang.String _weight
- The font weight
_style
protected java.lang.String _style
- The font style
BaseFont
public BaseFont(java.lang.String name,
java.lang.String weight,
java.lang.String style)
- Constructor for the base font requires the name, weight and style
attribute to be available as this forms the key to the font.
- Parameters:
name
- the name of the fontweight
- the weight of the fontstyle
- the style of the font
getName
public java.lang.String getName()
- Returns:
- the name of the font.
getStyle
public java.lang.String getStyle()
- Returns:
- the style (i.e. normal/italics)
getWeight
public java.lang.String getWeight()
- Returns:
- the weight (i.e. normal/bold)