|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.extex.font.format.xtf.tables.gps.LangSysRecord
public class LangSysRecord
Class for a langsys table.
| Constructor Summary | |
|---|---|
LangSysRecord(RandomAccessR rar)
Creates a new object. |
|
| Method Summary | |
|---|---|
int[] |
getFeatureIndex()
Getter for featureIndex. |
int |
getLookupOrderOffset()
Getter for lookupOrderOffset. |
int |
getOffset()
Getter for offset. |
int |
getReqFeatureIndex()
Getter for reqFeatureIndex. |
LanguageSystemTag |
getTag()
Getter for tag. |
void |
read(RandomAccessR rar,
int baseoffset)
Read the language system table. |
void |
writeXML(XMLStreamWriter writer)
Write the data to a XMLStreamWriter. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public LangSysRecord(RandomAccessR rar)
throws java.io.IOException
rar - input
java.io.IOException - if a io-error occurred.| Method Detail |
|---|
public int[] getFeatureIndex()
public int getLookupOrderOffset()
public int getOffset()
public int getReqFeatureIndex()
public LanguageSystemTag getTag()
public void read(RandomAccessR rar,
int baseoffset)
throws java.io.IOException
The Language System table (LangSys) identifies language-system features
used to render the glyphs in a script. (The LookupOrder offset is
reserved for future use.)
Optionally, a LangSys table may define a
Required Feature Index (ReqFeatureIndex) to specify one feature as
required within the context of a particular language system. For example,
in the Cyrillic script, the Serbian language system always renders
certain glyphs differently than the Russian language system.
Only
one feature index value can be tagged as the ReqFeatureIndex. This is not
a functional limitation, however, because the feature and lookup
definitions in OpenType Layout are structured so that one feature table
can reference many glyph substitution and positioning lookups. When no
required features are defined, then the ReqFeatureIndex is set to 0xFFFF.
All other features are optional. For each optional feature, a
zero-based index value references a record (FeatureRecord) in the
FeatureRecord array, which is stored in a Feature List table
(FeatureList). The feature indices themselves (excluding the
ReqFeatureIndex) are stored in arbitrary order in the FeatureIndex array.
The FeatureCount specifies the total number of features listed in the
FeatureIndex array.
Features are specified in full in the
FeatureList table, FeatureRecord, and Feature table, which are described
later in this chapter. Example 2 at the end of this chapter shows a
Script table, LangSysRecord, and LangSys table used for contextual
positioning in the Arabic script.
LangSys table
| Type | Name | Description |
| Offset | LookupOrder | = NULL (reserved for an offset to a reordering table) |
| uint16 | ReqFeatureIndex | Index of a feature required for this language system- if no required features = 0xFFFF |
| uint16 | FeatureCount | Number of FeatureIndex values for this language system-excludes the required feature |
| uint16 | FeatureIndex[FeatureCount] | Array of indices into the FeatureList-in arbitrary order |
rar - The input.baseoffset - The base offset.
java.io.IOException - if a io-error occurred.
public void writeXML(XMLStreamWriter writer)
throws java.io.IOException
XMLWriterConvertible
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 | |||||||||