public class TextRun extends Element
| Constructor and Description |
|---|
TextRun(java.lang.String text,
Font font,
GraphicState gstate,
TextState tstate,
Matrix matrix) |
| Modifier and Type | Method and Description |
|---|---|
void |
delete() |
double |
getAdvance()
Deprecated, use Text.GetAdvanceForTextRun(int textRunIndex) instead.
|
Font |
getFont()
The font of this TextRun.
|
GraphicState |
getGraphicState()
Get the graphic state of the text run.
|
byte[] |
getRawText()
The raw, un-interpreted text as char codes of this TextRun.
|
java.lang.String |
getText()
The text of this TextRun.
|
TextState |
getTextState()
The TextState of this TextRun.
|
void |
setFont(Font font)
The font of this TextRun.
|
void |
setGraphicState(GraphicState gstate)
Set the Graphic State of the text run.
|
void |
setText(java.lang.String text)
The text of this TextRun.
|
public TextRun(java.lang.String text,
Font font,
GraphicState gstate,
TextState tstate,
Matrix matrix)
public java.lang.String getText()
public void setText(java.lang.String text)
public byte[] getRawText()
public Font getFont()
public void setFont(Font font)
public double getAdvance()
The advance width of this run of text.
The advnace width is the amount by which the current point advances when the text run is drawn. Advance width is returned in user space.
public TextState getTextState()
public GraphicState getGraphicState()
May return null if this element does not have a GraphicState.
public void setGraphicState(GraphicState gstate)
gstate - the new/updated Graphic State for the text run.