java.lang.Object | |
↳ | com.pdftron.pdf.ShapedText |
The class ShapedText. A sequence of positioned glyphs -- the visual representation of a given text string
Nested Classes | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
class | ShapedText.FailureReason | ||||||||||
class | ShapedText.ShapingStatus |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
ShapedText(long impl_ptr) |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
long | __GetHandle() | ||||||||||
void |
close()
Frees the native memory of the object.
| ||||||||||
void |
destroy()
Frees the native memory of the object.
| ||||||||||
int |
getFailureReason()
In the case where GetShapingStatus() returns something other than FullShaping, this method will return a more detailed reason behind the failure.
| ||||||||||
int |
getGlyph(int index)
Get the glyph ID at the indicated place in the shaped sequence.
| ||||||||||
double |
getGlyphXPos(int index)
The X position of the glyph at the requested index.
| ||||||||||
double |
getGlyphYPos(int index)
The Y position of the glyph at the requested index.
| ||||||||||
int |
getNumGlyphs()
Number of glyphs present in the shaped text.
| ||||||||||
double |
getScale()
Scaling factor of this shaped text relative to the em size.
| ||||||||||
int |
getShapingStatus()
Get the state of the shaping operation.
| ||||||||||
String |
getText()
The original source text string.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
From interface
java.lang.AutoCloseable
|
Frees the native memory of the object. This can be explicity called to control the deallocation of native memory and avoid situations where the garbage collector does not free the object in a timely manner.
PDFNetException |
---|
Frees the native memory of the object. This can be explicity called to control the deallocation of native memory and avoid situations where the garbage collector does not free the object in a timely manner.
PDFNetException |
---|
In the case where GetShapingStatus() returns something other than FullShaping, this method will return a more detailed reason behind the failure.
PDFNetException |
---|
Get the glyph ID at the indicated place in the shaped sequence. This number is specific to the font file used to generate the shaping results, and does not always have a clean mapping to a particular Unicode codepoint in the original string.
index | -- the index of the glyph to be retrieved. Must be less than GetNumGlyphs() |
---|
PDFNetException |
---|
The X position of the glyph at the requested index. This number has been scaled by GetScale().
index | -- the index of the glyph position to be retrieved. Must be less than GetNumGlyphs() |
---|
PDFNetException |
---|
The Y position of the glyph at the requested index. This number has been scaled by GetScale().
index | -- the index of the glyph position to be retrieved. Must be less than GetNumGlyphs() |
---|
PDFNetException |
---|
Number of glyphs present in the shaped text. Might be different from the .
PDFNetException |
---|
Scaling factor of this shaped text relative to the em size. A scaling factor of 1 means that all units are relative to the em size. PDF scaling is typically 1000 units per em.
PDFNetException |
---|
Get the state of the shaping operation. Even if the shaping did not fully succeed, this object can be added to an elementbuilder, and will fallback to placing unshped text. See GetFailureReason() in the case this method returns something other than FullShaping.
PDFNetException |
---|