Modifier and Type | Field and Description |
---|---|
static int |
CMAP_TABLE
Well known tables
|
static int |
GLYF_TABLE |
static int |
HEAD_TABLE |
static int |
HHEA_TABLE |
static int |
HMTX_TABLE |
static int |
LOCA_TABLE |
static int |
MAXP_TABLE |
static int |
NAME_TABLE |
static int |
POST_TABLE |
Modifier | Constructor and Description |
---|---|
protected |
TrueTypeTable(int tag)
Creates a new instance of TrueTypeTable.
|
Modifier and Type | Method and Description |
---|---|
static TrueTypeTable |
createTable(TrueTypeFont ttf,
java.lang.String tagString)
Get a new instance of an empty table by tag string
|
static TrueTypeTable |
createTable(TrueTypeFont ttf,
java.lang.String tagString,
java.nio.ByteBuffer data)
Get a new instance of a table with provided data
|
java.nio.ByteBuffer |
getData()
Get the data in the table
|
int |
getLength()
Get the size of the table, in bytes
|
int |
getTag()
Get the table's tag
|
void |
setData(java.nio.ByteBuffer data)
Set the data in the table
|
static int |
stringToTag(java.lang.String tag)
Turn a string into a tag
|
static java.lang.String |
tagToString(int tag)
Get the tag as a string
|
java.lang.String |
toString()
Put into a nice string
|
public static final int CMAP_TABLE
public static final int GLYF_TABLE
public static final int HEAD_TABLE
public static final int HHEA_TABLE
public static final int HMTX_TABLE
public static final int MAXP_TABLE
public static final int NAME_TABLE
public static final int POST_TABLE
public static final int LOCA_TABLE
protected TrueTypeTable(int tag)
getTable()
methods
to get new instances.tag
- the tag for this tablepublic static TrueTypeTable createTable(TrueTypeFont ttf, java.lang.String tagString)
ttf
- the font that contains this tabletagString
- the tag for this table, as a 4 character string
(e.g. head or cmap)public static TrueTypeTable createTable(TrueTypeFont ttf, java.lang.String tagString, java.nio.ByteBuffer data)
ttf
- the font that contains this tabletagString
- the tag for this table, as a 4 character string
(e.g. head or cmap)data
- the table datapublic int getTag()
public java.nio.ByteBuffer getData()
public void setData(java.nio.ByteBuffer data)
public int getLength()
public static java.lang.String tagToString(int tag)
public static int stringToTag(java.lang.String tag)
public java.lang.String toString()
toString
in class java.lang.Object