Class MetaFont
- java.lang.Object
-
- com.itextpdf.kernel.pdf.canvas.wmf.MetaObject
-
- com.itextpdf.kernel.pdf.canvas.wmf.MetaFont
-
public class MetaFont extends MetaObject
A Meta Font.
-
-
Field Summary
Fields Modifier and Type Field Description (package private) floatangle(package private) intbold(package private) static intBOLDTHRESHOLD(package private) intcharset(package private) static intDEFAULT_PITCH(package private) FontEncodingencoding(package private) static intETO_CLIPPED(package private) static intETO_OPAQUE(package private) java.lang.StringfaceName(package private) static intFF_DECORATIVE(package private) static intFF_DONTCARE(package private) static intFF_MODERN(package private) static intFF_ROMAN(package private) static intFF_SCRIPT(package private) static intFF_SWISS(package private) static intFIXED_PITCH(package private) FontProgramfont(package private) static java.lang.String[]fontNames(package private) intheight(package private) intitalic(package private) static intMARKER_BOLD(package private) static intMARKER_COURIER(package private) static intMARKER_HELVETICA(package private) static intMARKER_ITALIC(package private) static intMARKER_SYMBOL(package private) static intMARKER_TIMES(package private) static intNAME_SIZE(package private) intpitchAndFamily(package private) booleanstrikeout(package private) booleanunderline(package private) static intVARIABLE_PITCH-
Fields inherited from class com.itextpdf.kernel.pdf.canvas.wmf.MetaObject
META_BRUSH, META_FONT, META_NOT_SUPPORTED, META_PEN
-
-
Constructor Summary
Constructors Constructor Description MetaFont()Creates a MetaFont instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description floatgetAngle()Returns the angle of the MetaFont.FontEncodinggetEncoding()Returns the encoding used in the MetaFont.FontProgramgetFont()Returns the Font.floatgetFontSize(MetaState state)Returns the font size.voidinit(InputMeta in)Initializes the MetaFont instance.booleanisStrikeout()Returns a boolean value indicating if a font has a strikeout.booleanisUnderline()Returns a boolean value indicating if the font is underlined or not.-
Methods inherited from class com.itextpdf.kernel.pdf.canvas.wmf.MetaObject
getType
-
-
-
-
Field Detail
-
fontNames
static final java.lang.String[] fontNames
-
MARKER_BOLD
static final int MARKER_BOLD
- See Also:
- Constant Field Values
-
MARKER_ITALIC
static final int MARKER_ITALIC
- See Also:
- Constant Field Values
-
MARKER_COURIER
static final int MARKER_COURIER
- See Also:
- Constant Field Values
-
MARKER_HELVETICA
static final int MARKER_HELVETICA
- See Also:
- Constant Field Values
-
MARKER_TIMES
static final int MARKER_TIMES
- See Also:
- Constant Field Values
-
MARKER_SYMBOL
static final int MARKER_SYMBOL
- See Also:
- Constant Field Values
-
DEFAULT_PITCH
static final int DEFAULT_PITCH
- See Also:
- Constant Field Values
-
FIXED_PITCH
static final int FIXED_PITCH
- See Also:
- Constant Field Values
-
VARIABLE_PITCH
static final int VARIABLE_PITCH
- See Also:
- Constant Field Values
-
FF_DONTCARE
static final int FF_DONTCARE
- See Also:
- Constant Field Values
-
FF_ROMAN
static final int FF_ROMAN
- See Also:
- Constant Field Values
-
FF_SWISS
static final int FF_SWISS
- See Also:
- Constant Field Values
-
FF_MODERN
static final int FF_MODERN
- See Also:
- Constant Field Values
-
FF_SCRIPT
static final int FF_SCRIPT
- See Also:
- Constant Field Values
-
FF_DECORATIVE
static final int FF_DECORATIVE
- See Also:
- Constant Field Values
-
BOLDTHRESHOLD
static final int BOLDTHRESHOLD
- See Also:
- Constant Field Values
-
NAME_SIZE
static final int NAME_SIZE
- See Also:
- Constant Field Values
-
ETO_OPAQUE
static final int ETO_OPAQUE
- See Also:
- Constant Field Values
-
ETO_CLIPPED
static final int ETO_CLIPPED
- See Also:
- Constant Field Values
-
height
int height
-
angle
float angle
-
bold
int bold
-
italic
int italic
-
underline
boolean underline
-
strikeout
boolean strikeout
-
charset
int charset
-
pitchAndFamily
int pitchAndFamily
-
faceName
java.lang.String faceName
-
font
FontProgram font
-
encoding
FontEncoding encoding
-
-
Method Detail
-
init
public void init(InputMeta in) throws java.io.IOException
Initializes the MetaFont instance.- Parameters:
in- InputMeta containing the WMF data- Throws:
java.io.IOException- anIOException
-
getFont
public FontProgram getFont() throws java.io.IOException
Returns the Font.- Returns:
- the font
- Throws:
java.io.IOException- anIOException
-
getEncoding
public FontEncoding getEncoding()
Returns the encoding used in the MetaFont.- Returns:
- the font encoding
-
getAngle
public float getAngle()
Returns the angle of the MetaFont.- Returns:
- the angle
-
isUnderline
public boolean isUnderline()
Returns a boolean value indicating if the font is underlined or not.- Returns:
- true if the font is underlined
-
isStrikeout
public boolean isStrikeout()
Returns a boolean value indicating if a font has a strikeout.- Returns:
- true if the font set strikeout
-
getFontSize
public float getFontSize(MetaState state)
Returns the font size.- Parameters:
state- the MetaState- Returns:
- font size
-
-