|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectadams.core.io.PdfFont
public class PdfFont
A helper class for PDF fonts.
| Field Summary | |
|---|---|
static String |
BOLD
the string for BOLD. |
static String |
COURIER
the string for Courier. |
static String |
HELVETICA
the string for Helvetica. |
static String |
ITALIC
the string for ITALIC. |
protected com.itextpdf.text.Font |
m_Font
the actual PDF font. |
protected int |
m_FontFace
the font face. |
protected int |
m_FontFamily
the font family. |
protected float |
m_Size
the font size. |
static String |
NORMAL
the string for NORMAL. |
static char |
SEPARATOR
the separator. |
static String |
STRIKETHRU
the string for STRIKETHRU. |
static String |
SYMBOL
the string for Symbol. |
static String |
TIMES_ROMAN
the string for Times Roman. |
static String |
UNDERLINE
the string for UNDERLINE. |
static String |
ZAPFDINGBATS
the string for ZapfDingBats. |
| Constructor Summary | |
|---|---|
PdfFont()
Initializes a default font. |
|
PdfFont(int family,
int face,
float size)
Initializes the font with the given values. |
|
PdfFont(String fontStr)
Parses the given string. |
|
PdfFont(String family,
int face,
float size)
Initializes the font with the given values. |
|
PdfFont(String family,
String face,
float size)
Initializes the font with the given values. |
|
| Method Summary | |
|---|---|
PdfFont |
getClone()
Returns a clone of the object. |
int |
getFontFace()
Returns the font face. |
static int |
getFontFace(String name)
Turns the font style name into the constant of the font style. |
String[] |
getFontFaces()
Generates a list of font faces. |
static String[] |
getFontFaces(com.itextpdf.text.Font font)
Generates a list of font style names from the given font setup. |
int |
getFontFamily()
Turns the font family into the String constant of the font family. |
static String |
getFontFamily(com.itextpdf.text.Font font)
Turns the font family into the String constant of the font family. |
static String |
getFontFamily(int family)
Turns the font family into the String constant of the font family. |
static int |
getFontFamily(String name)
Turns the font family name into the constant of the font family. |
static com.itextpdf.text.Font.FontFamily |
getFontFamilyEnum(int family)
Turns the font family into the enum of the font family. |
String |
getFontFamilyName()
Turns the font family into the String constant of the font family. |
float |
getSize()
Returns the font size. |
com.itextpdf.text.Font |
toFont()
Turns the font object into the PDF font. |
com.itextpdf.text.Font |
toFont(Color color)
Turns the font object into the PDF font. |
Font |
toJavaFont()
Returns the closest Java font. |
String |
toString()
Returns the font as string. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final char SEPARATOR
public static final String NORMAL
public static final String BOLD
public static final String ITALIC
public static final String STRIKETHRU
public static final String UNDERLINE
public static final String COURIER
public static final String HELVETICA
public static final String SYMBOL
public static final String TIMES_ROMAN
public static final String ZAPFDINGBATS
protected int m_FontFamily
protected int m_FontFace
protected float m_Size
protected transient com.itextpdf.text.Font m_Font
| Constructor Detail |
|---|
public PdfFont()
public PdfFont(String family,
String face,
float size)
family - the font family (helvetica, etc)face - the font face (bold, etc)size - the size of the font
public PdfFont(String family,
int face,
float size)
family - the font family (helvetica, etc)face - the font face (bold, etc)size - the size of the font
public PdfFont(int family,
int face,
float size)
family - the font family (helvetica, etc)face - the font face (bold, etc)size - the size of the fontpublic PdfFont(String fontStr)
fontStr - the string to parse| Method Detail |
|---|
public int getFontFamily()
public String getFontFamilyName()
public int getFontFace()
public String[] getFontFaces()
public float getSize()
public PdfFont getClone()
getClone in interface CloneHandler<PdfFont>public String toString()
toString in class Objectpublic com.itextpdf.text.Font toFont()
public com.itextpdf.text.Font toFont(Color color)
color - the color to use
public Font toJavaFont()
public static int getFontFamily(String name)
name - the font family name
public static String getFontFamily(com.itextpdf.text.Font font)
font - the font to analyze
public static com.itextpdf.text.Font.FontFamily getFontFamilyEnum(int family)
family - the family to analyze
public static String getFontFamily(int family)
family - the family to analyze
public static int getFontFace(String name)
name - the font style name
public static String[] getFontFaces(com.itextpdf.text.Font font)
font - the font to analyze
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||