public class CharacterSetOrientation
extends java.lang.Object
Constructor and Description |
---|
CharacterSetOrientation(int orientation,
int spaceIncrement,
int emSpaceIncrement,
int nomCharIncrement)
Constructor for the CharacterSetOrientation, the orientation is
expressed as the degrees rotation (i.e 0, 90, 180, 270)
|
Modifier and Type | Method and Description |
---|---|
int |
getAscender()
Ascender height is the distance from the character baseline to the
top of the character box.
|
int |
getCapHeight()
Cap height is the average height of the uppercase characters in
a font.
|
java.awt.Rectangle |
getCharacterBox(char character,
int size)
Get the character box (rectangle with dimensions in 1/1000ths of a point size) of the character
identified by the parameter passed.
|
int |
getDescender()
Descender depth is the distance from the character baseline to
the bottom of a character box.
|
int |
getEmSpaceIncrement()
Returns the em space increment.
|
int |
getNominalCharIncrement()
Returns the nominal character increment.
|
int |
getOrientation()
The orientation for these metrics in the character set
|
int |
getSpaceIncrement()
Returns the space increment.
|
int |
getUnderscorePosition() |
int |
getUnderscoreWidth() |
int |
getWidth(char character,
int size)
Get the width (in 1/1000ths of a point size) of the character
identified by the parameter passed.
|
int |
getXHeight()
XHeight refers to the height of the lower case letters above
the baseline.
|
void |
setAscender(int ascender)
Ascender height is the distance from the character baseline to the
top of the character box.
|
void |
setCapHeight(int capHeight)
Cap height is the average height of the uppercase characters in
a font.
|
void |
setCharacterMetrics(char character,
int width,
java.awt.Rectangle characterBox)
Set the width (in 1/1000ths of a point size) of the character
identified by the parameter passed.
|
void |
setDescender(int descender)
Descender depth is the distance from the character baseline to
the bottom of a character box.
|
void |
setUnderscorePosition(int underscorePosition)
TODO
|
void |
setUnderscoreWidth(int underscoreWidth)
TODO
|
void |
setXHeight(int xHeight)
XHeight refers to the height of the lower case letters above
the baseline.
|
public CharacterSetOrientation(int orientation, int spaceIncrement, int emSpaceIncrement, int nomCharIncrement)
orientation
- the character set orientationspaceIncrement
- the space incrementemSpaceIncrement
- the em space incrementnomCharIncrement
- the nominal character incrementpublic int getAscender()
public int getCapHeight()
public int getDescender()
public int getUnderscoreWidth()
public int getUnderscorePosition()
public int getOrientation()
public int getXHeight()
public int getWidth(char character, int size)
character
- the Unicode character to evaluatesize
- the font sizepublic java.awt.Rectangle getCharacterBox(char character, int size)
character
- the Unicode character to evaluatesize
- the font sizepublic void setAscender(int ascender)
ascender
- the ascender to setpublic void setCapHeight(int capHeight)
capHeight
- the cap height to setpublic void setDescender(int descender)
descender
- the descender value in millipointspublic void setUnderscoreWidth(int underscoreWidth)
underscoreWidth
- the underscore width value in millipointspublic void setUnderscorePosition(int underscorePosition)
underscorePosition
- the underscore position value in millipointspublic void setCharacterMetrics(char character, int width, java.awt.Rectangle characterBox)
character
- the Unicode character for which the width is being setwidth
- the widths of the charactercharacterBox
- the character boxpublic void setXHeight(int xHeight)
xHeight
- the typical height of characterspublic int getSpaceIncrement()
public int getEmSpaceIncrement()
public int getNominalCharIncrement()
Copyright 1999-2017 The Apache Software Foundation. All Rights Reserved.