|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.extex.font.format.xtf.tables.AbstractXtfTable
org.extex.font.format.xtf.tables.TtfTableHMTX
public class TtfTableHMTX
The 'hmtx' table contains metric information for the horizontal layout each of the glyphs in the font.
| Field | Type | Description |
| hMetrics | longHorMetric[numberOfHMetrics] | Paired advance width and left side bearing values for each glyph. The value numOfHMetrics comes from the ‘hhea’ table. If the font is monospaced, only one entry need be in the array, but that entry is required. The last entry applies to all subsequent glyphs. |
| leftSideBearing | FWord[ ] | Here the advanceWidth is assumed to be the same as the advanceWidth for the last entry above. The number of entries in this array is derived from numGlyphs (from ‘maxp’ table) minus numberOfHMetrics. This generally is used with a run of monospaced glyphs (e.g., Kanji fonts or Courier fonts). Only one run is allowed and it must be at the end. This allows a monospaced font to vary the left side bearing values for each glyph. |
| Constructor Summary | |
|---|---|
TtfTableHMTX(XtfTableMap tablemap,
XtfTableDirectory.Entry de,
RandomAccessR rar)
Create a new object |
|
| Method Summary | |
|---|---|
int |
getAdvanceWidth(int i)
Returns the advanced width |
int |
getInitOrder()
Returns a order number to sort the tables for the init process. |
short |
getLeftSideBearing(int i)
Return the left side bearing |
java.lang.String |
getShortcut()
Returns the table shortcut. |
int |
getType()
Get the table type, as a table directory value. |
void |
init()
Initialize the table. |
void |
writeXML(XMLStreamWriter writer)
Write the data to a XMLStreamWriter. |
| Methods inherited from class org.extex.font.format.xtf.tables.AbstractXtfTable |
|---|
getGlyphName, getTableMap, writeStartElement |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.extex.font.format.xtf.tables.XtfTable |
|---|
getTableMap |
| Constructor Detail |
|---|
public TtfTableHMTX(XtfTableMap tablemap,
XtfTableDirectory.Entry de,
RandomAccessR rar)
throws java.io.IOException
tablemap - the tablemapde - entrayrar - input
java.io.IOException - if an IO-error occurs| Method Detail |
|---|
public int getAdvanceWidth(int i)
i - index
public int getInitOrder()
getInitOrder in interface XtfTablegetInitOrder in class AbstractXtfTableAbstractXtfTable.getInitOrder()public short getLeftSideBearing(int i)
i - index
public java.lang.String getShortcut()
getShortcut in interface XtfTableXtfTable.getShortcut()public int getType()
getType in interface XtfTablepublic void init()
AbstractXtfTable
init in interface XtfTableinit in class AbstractXtfTableAbstractXtfTable.init()
public void writeXML(XMLStreamWriter writer)
throws java.io.IOException
writeXML in interface XMLWriterConvertiblewriter - the XML-Writer
java.io.IOException - if an IO-error occurs.XMLWriterConvertible.writeXML(
org.extex.util.xml.XMLStreamWriter)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||