public class CIDSubset extends java.lang.Object implements CIDSet
Constructor and Description |
---|
CIDSubset(MultiByteFont mbf) |
Modifier and Type | Method and Description |
---|---|
char[] |
getChars()
Returns a char array containing all Unicode characters that are in the subset.
|
int |
getGIDFromChar(char ch)
Returns the glyph index from the original font from a character
|
java.util.BitSet |
getGlyphIndices()
Returns a BitSet with bits set for each available glyph index in the subset.
|
java.util.Map<java.lang.Integer,java.lang.Integer> |
getGlyphs()
Returns an unmodifiable Map of the font subset.
|
int |
getNumberOfGlyphs()
Returns the number of glyphs in the subset.
|
int |
getOriginalGlyphIndex(int index)
Returns the original index of the glyph inside the (non-subset) font's glyph list.
|
char |
getUnicode(int index)
Returns the Unicode value for a subset index (character selector).
|
char |
getUnicodeFromGID(int glyphIndex)
Gets the unicode character from the original font glyph index
|
int[] |
getWidths()
Return the array of widths.
|
int |
mapChar(int glyphIndex,
char unicode)
Maps a character to a character selector for a font subset.
|
public CIDSubset(MultiByteFont mbf)
public int getOriginalGlyphIndex(int index)
getOriginalGlyphIndex
in interface CIDSet
index
- the subset index (character selector) to access the glyphpublic char getUnicode(int index)
getUnicode
in interface CIDSet
index
- the subset index (character selector)public int mapChar(int glyphIndex, char unicode)
public java.util.Map<java.lang.Integer,java.lang.Integer> getGlyphs()
public char getUnicodeFromGID(int glyphIndex)
getUnicodeFromGID
in interface CIDSet
glyphIndex
- The original glyph index of the character in the fontpublic int getGIDFromChar(char ch)
getGIDFromChar
in interface CIDSet
ch
- The characterpublic char[] getChars()
public int getNumberOfGlyphs()
getNumberOfGlyphs
in interface CIDSet
public java.util.BitSet getGlyphIndices()
getGlyphIndices
in interface CIDSet
Copyright 1999-2017 The Apache Software Foundation. All Rights Reserved.