class PdfFont extends Object implements Comparable<PdfFont>
PdfFont
is the Pdf Font object.
Limitation: in this class only base 14 Type 1 fonts (courier, courier bold, courier oblique,
courier boldoblique, helvetica, helvetica bold, helvetica oblique, helvetica boldoblique,
symbol, times roman, times bold, times italic, times bolditalic, zapfdingbats) and their
standard encoding (standard, MacRoman, (MacExpert,) WinAnsi) are supported.
This object is described in the 'Portable Document Format Reference Manual version 1.3'
section 7.7 (page 198-203).
PdfName
,
PdfDictionary
,
BadPdfFormatException
Modifier and Type | Field and Description |
---|---|
private BaseFont |
font
the font metrics.
|
protected float |
hScale |
protected Image |
image
an image.
|
private float |
size
the size.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(PdfFont pdfFont)
Compares this
PdfFont with another |
(package private) static PdfFont |
getDefaultFont() |
(package private) BaseFont |
getFont() |
(package private) float |
getHorizontalScaling()
Getter for the horizontal scaling.
|
(package private) void |
setHorizontalScaling(float hScale) |
(package private) void |
setImage(Image image) |
(package private) float |
size()
Returns the size of this font.
|
(package private) float |
width()
Returns the approximative width of 1 character of this font.
|
(package private) float |
width(int character)
Returns the width of a certain character of this font.
|
(package private) float |
width(String s) |
public int compareTo(PdfFont pdfFont)
PdfFont
with anothercompareTo
in interface Comparable<PdfFont>
pdfFont
- the other PdfFont
float size()
float width()
float width(int character)
character
- a certain characterstatic PdfFont getDefaultFont()
void setHorizontalScaling(float hScale)
float getHorizontalScaling()
WebARTS Library Licensed Under the GNU - General Public License. Other Libraries licensed under their respective Open Source Licenses