public class FormattedTextFragmentCollection extends RemoveOnlyListBase<FormattedTextFragment>
This collection contains the items of
base type.FormattedTextFragment
Modifier and Type | Method and Description |
---|---|
void |
add(String text)
Adds a formatted text fragment to the collection.
|
void |
add(String text,
Font font)
Adds a formatted text fragment to the collection.
|
void |
add(String text,
Font font,
Color foregroundColor)
Adds a formatted text fragment to the collection.
|
void |
add(String text,
Font font,
Color foregroundColor,
Color backgroundColor)
Adds a formatted text fragment to the collection.
|
int |
getCollectionType()
Gets the formatted fragment collection type.
|
void |
insert(int index,
String text)
Inserts a formatted text fragment into the collection at a given index.
|
void |
insert(int index,
String text,
Font font)
Inserts a formatted text fragment into the collection at a given index.
|
void |
insert(int index,
String text,
Font font,
Color foregroundColor)
Inserts a formatted text fragment into the collection at a given index.
|
void |
insert(int index,
String text,
Font font,
Color foregroundColor,
Color backgroundColor)
Inserts a formatted text fragment into the collection at a given index.
|
clear, isReadOnly, remove, removeAt
public final int getCollectionType()
Gets the formatted fragment collection type.
public final void add(String text)
Adds a formatted text fragment to the collection.
text
- The fragment text.public final void add(String text, Font font)
Adds a formatted text fragment to the collection.
text
- The fragment text.font
- The font of the text.public final void add(String text, Font font, Color foregroundColor)
Adds a formatted text fragment to the collection.
text
- The fragment text.font
- The font of the text.foregroundColor
- The foreground color of the text.public final void add(String text, Font font, Color foregroundColor, Color backgroundColor)
Adds a formatted text fragment to the collection.
text
- The fragment text.font
- The font of the text.foregroundColor
- The foreground color of the text.backgroundColor
- The background color of the text.public final void insert(int index, String text)
Inserts a formatted text fragment into the collection at a given index.
index
- The zero-based index at which formatted text fragment should be inserted.text
- The fragment text.public final void insert(int index, String text, Font font)
Inserts a formatted text fragment into the collection at a given index.
index
- The zero-based index at which formatted text fragment should be inserted.text
- The fragment text.font
- The font of the text.public final void insert(int index, String text, Font font, Color foregroundColor)
Inserts a formatted text fragment into the collection at a given index.
index
- The zero-based index at which formatted text fragment should be inserted.text
- The fragment text.font
- The font of the text.foregroundColor
- The foreground color of the text.public final void insert(int index, String text, Font font, Color foregroundColor, Color backgroundColor)
Inserts a formatted text fragment into the collection at a given index.
index
- The zero-based index at which formatted text fragment should be inserted.text
- The fragment text.font
- The font of the text.foregroundColor
- The foreground color of the text.backgroundColor
- The background color of the text.