|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.poi.hslf.model.TextRun
public final class TextRun
This class represents a run of text in a powerpoint document. That run could be text on a sheet, or text in a note. It is only a very basic class for now
| Constructor Summary | |
|---|---|
TextRun(TextHeaderAtom tha,
TextBytesAtom tba,
StyleTextPropAtom sta)
Constructs a Text Run from a Ascii text block |
|
TextRun(TextHeaderAtom tha,
TextCharsAtom tca,
StyleTextPropAtom sta)
Constructs a Text Run from a Unicode text block |
|
| Method Summary | |
|---|---|
RichTextRun |
appendText(java.lang.String s)
Adds the supplied text onto the end of the TextRun, creating a new RichTextRun (returned) for it to sit in. |
void |
buildRichTextRuns(java.util.LinkedList pStyles,
java.util.LinkedList cStyles,
java.lang.String runRawText)
|
void |
changeTextInRichTextRun(RichTextRun run,
java.lang.String s)
Handles an update to the text stored in one of the Rich Text Runs |
TextRulerAtom |
createTextRuler()
|
void |
ensureStyleAtomPresent()
Ensure a StyleTextPropAtom is present for this run, by adding if required. |
Hyperlink[] |
getHyperlinks()
Returns the array of all hyperlinks in this text run |
java.lang.String |
getRawText()
Returns the raw text content of the run. |
Record[] |
getRecords()
Returns records that make up this text run |
RichTextRun |
getRichTextRunAt(int pos)
Fetch RichTextRun at a given position |
RichTextRun[] |
getRichTextRuns()
Fetch the rich text runs (runs of text with the same styling) that are contained within this block of text |
int |
getRunType()
Returns the type of the text, from the TextHeaderAtom. |
Sheet |
getSheet()
|
java.lang.String |
getText()
Returns the text content of the run, which has been made safe for printing and other use. |
TextRulerAtom |
getTextRuler()
|
java.lang.String |
normalize(java.lang.String s)
Returns a new string with line breaks converted into internal ppt representation |
void |
setRawText(java.lang.String s)
Changes the text, and sets it all to have the same styling as the the first character has. |
void |
setRunType(int type)
Changes the type of the text. |
void |
setSheet(Sheet sheet)
|
void |
setText(java.lang.String s)
Changes the text. |
void |
supplySlideShow(SlideShow ss)
Supply the SlideShow we belong to. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public TextRun(TextHeaderAtom tha,
TextCharsAtom tca,
StyleTextPropAtom sta)
tha - the TextHeaderAtom that defines what's whattca - the TextCharsAtom containing the textsta - the StyleTextPropAtom which defines the character stylings
public TextRun(TextHeaderAtom tha,
TextBytesAtom tba,
StyleTextPropAtom sta)
tha - the TextHeaderAtom that defines what's whattba - the TextBytesAtom containing the textsta - the StyleTextPropAtom which defines the character stylings| Method Detail |
|---|
public void buildRichTextRuns(java.util.LinkedList pStyles,
java.util.LinkedList cStyles,
java.lang.String runRawText)
public RichTextRun appendText(java.lang.String s)
public void changeTextInRichTextRun(RichTextRun run,
java.lang.String s)
run - s - public void setRawText(java.lang.String s)
public void setText(java.lang.String s)
public void ensureStyleAtomPresent()
public java.lang.String getText()
public java.lang.String getRawText()
public RichTextRun[] getRichTextRuns()
public int getRunType()
TextHeaderAtompublic void setRunType(int type)
TextHeaderAtompublic void supplySlideShow(SlideShow ss)
public void setSheet(Sheet sheet)
public Sheet getSheet()
public Hyperlink[] getHyperlinks()
null if not found.public RichTextRun getRichTextRunAt(int pos)
pos - 0-based index in the text
public TextRulerAtom getTextRuler()
public TextRulerAtom createTextRuler()
public java.lang.String normalize(java.lang.String s)
public Record[] getRecords()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||