|
jPod PDF library | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.intarsys.pdf.encoding.Encoding
de.intarsys.pdf.font.DifferenceEncoding
public class DifferenceEncoding
An encoding defined as a delta to another base encoding.
the encoding difference is defined in the form ... num name name name num name.. ...
where num is the codepoint for the first glyph name in the list. The following names are mapped to the codepoint of the predecessor + 1. Multiple redefinition offsets can be defined.
Field Summary | |
---|---|
static COSName |
DK_BaseEncoding
|
static COSName |
DK_Differences
|
Method Summary | |
---|---|
COSObject |
cosGetObject()
Get an object that can be used as a representation of the receiver encoding within doc . |
static Encoding |
create(COSDictionary dict,
PDFont font)
Create the difference encoding from the values defined in the dict . |
int |
getDecoded(int codepoint)
Get the character for the codepoint or -1 if not available. |
int |
getDifferenceDecoded(int codePoint)
|
String |
getDifferenceGlyphName(int codePoint)
|
int |
getEncoded(int character)
Get the codepoint for the the character or -1 if invalid. |
int |
getEncoded(String name)
Get the codepoint for the the named character or -1 if invalid. |
String |
getGlyphName(int codePoint)
Get the character name for a given encoded codepoint. |
String |
getName()
The name of this encoding. |
boolean |
isFontSpecificEncoding()
Answer true if this encoding is specific to and embedded into the font program itself so that we can not derive any mapping information from here. |
Methods inherited from class de.intarsys.pdf.encoding.Encoding |
---|
createNamed, createReader, createWriter, decode, decode, decode, encode, encode, encode, encode, getNextDecoded, getNextEncoded, getValidEncoded, getValidEncoded, isEncodable, isEncodable, isEncodable, putNextDecoded, putNextEncoded, toString |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final COSName DK_Differences
public static final COSName DK_BaseEncoding
Method Detail |
---|
public static Encoding create(COSDictionary dict, PDFont font)
dict
.
dict
- The dictionary defining the difference.font
- The font defining the base encoding.
dict
.public COSObject cosGetObject()
Encoding
doc
.
cosGetObject
in class Encoding
doc
.public int getDecoded(int codepoint)
Encoding
getDecoded
in class Encoding
codepoint
- The codepoint
public int getDifferenceDecoded(int codePoint)
getDifferenceDecoded
in class Encoding
public String getDifferenceGlyphName(int codePoint)
getDifferenceGlyphName
in class Encoding
public int getEncoded(int character)
Encoding
getEncoded
in class Encoding
character
- The character to look up.
public int getEncoded(String name)
Encoding
getEncoded
in class Encoding
name
- The character name to look up.
public String getGlyphName(int codePoint)
Encoding
getGlyphName
in class Encoding
codePoint
- The encoded codepoint.
codepoint
or ".notdef".public String getName()
Encoding
getName
in class Encoding
public boolean isFontSpecificEncoding()
Encoding
isFontSpecificEncoding
in class Encoding
|
jPod PDF library | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |