|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.poi.hssf.usermodel.HSSFRichTextString
Rich text unicode string. These strings can have fonts applied to arbitary parts of the string.
Field Summary | |
static short |
NO_FONT
Place holder for indicating that NO_FONT has been applied here |
Constructor Summary | |
HSSFRichTextString()
|
|
HSSFRichTextString(java.lang.String string)
|
Method Summary | |
void |
applyFont(HSSFFont font)
Sets the font of the entire string. |
void |
applyFont(int startIndex,
int endIndex,
HSSFFont font)
Applies a font to the specified characters of a string. |
void |
applyFont(int startIndex,
int endIndex,
short fontIndex)
Applies a font to the specified characters of a string. |
void |
applyFont(short fontIndex)
Applies the specified font to the entire string. |
int |
compareTo(java.lang.Object o)
Compares one rich text string to another. |
short |
getFontAtIndex(int index)
Returns the font in use at a particular index. |
short |
getFontOfFormattingRun(int index)
Gets the font used in a particular formatting run. |
int |
getIndexOfFormattingRun(int index)
The index within the string to which the specified formatting run applies. |
java.lang.String |
getString()
Returns the plain string representation. |
int |
length()
|
int |
numFormattingRuns()
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final short NO_FONT
Constructor Detail |
public HSSFRichTextString()
public HSSFRichTextString(java.lang.String string)
Method Detail |
public void applyFont(int startIndex, int endIndex, short fontIndex)
startIndex
- The start index to apply the font to (inclusive)endIndex
- The end index to apply the font to (exclusive)fontIndex
- The font to use.public void applyFont(int startIndex, int endIndex, HSSFFont font)
startIndex
- The start index to apply the font to (inclusive)endIndex
- The end index to apply to font to (exclusive)font
- The index of the font to use.public void applyFont(HSSFFont font)
font
- The font to use.public java.lang.String getString()
public int length()
public short getFontAtIndex(int index)
index
- The index.
public int numFormattingRuns()
NO_FONT
public int getIndexOfFormattingRun(int index)
index
- the index of the formatting run
public short getFontOfFormattingRun(int index)
index
- the index of the formatting run
public int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
public java.lang.String toString()
public void applyFont(short fontIndex)
fontIndex
- the font to apply.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |