public class List extends BlockElement<List>
ListItem objects that can optionally be prefixed
with a symbol and/or numbered.| Modifier and Type | Field and Description |
|---|---|
static String |
DEFAULT_LIST_SYMBOL |
protected DefaultAccessibilityProperties |
tagProperties |
childElements, nextRenderer, stylesproperties| Constructor and Description |
|---|
List()
Creates a List with the
DEFAULT_LIST_SYMBOL as a prefix. |
List(ListNumberingType listNumberingType)
Creates a List with a custom numbering type.
|
| Modifier and Type | Method and Description |
|---|---|
List |
add(ListItem listItem)
Adds a new
ListItem to the bottom of the List. |
List |
add(String text)
Adds a new
ListItem to the bottom of the List. |
AccessibilityProperties |
getAccessibilityProperties()
Gets the
accessibility properties. |
<T1> T1 |
getDefaultProperty(int property)
Gets the default property from this entity.
|
String |
getPostSymbolText()
Gets the piece of text that is added after the
ListItem symbol. |
String |
getPreSymbolText()
Gets the piece of text that is added before the
ListItem symbol. |
Float |
getSymbolIndent()
Gets the indent offset of the
ListItem symbols. |
protected IRenderer |
makeNewRenderer() |
List |
setItemStartIndex(int start)
Customizes the index of the first item in the list.
|
List |
setListSymbol(Image image)
Sets the list symbol to be used.
|
List |
setListSymbol(ListNumberingType listNumberingType)
Sets the list numbering type to be used.
|
List |
setListSymbol(String symbol)
Sets the list symbol to be used.
|
List |
setListSymbol(Text text)
Sets the list symbol to be used.
|
List |
setListSymbolAlignment(ListSymbolAlignment alignment)
A specialized enum containing alignment properties for list symbols.
|
void |
setPostSymbolText(String postSymbolText)
Sets a piece of text that should be added after the
ListItem symbol. |
void |
setPreSymbolText(String preSymbolText)
Sets a piece of text that should be added before the
ListItem symbol. |
List |
setSymbolIndent(float symbolIndent)
Sets the indent offset of the
ListItem symbols. |
getHeight, getMarginBottom, getMarginLeft, getMarginRight, getMarginTop, getPaddingBottom, getPaddingLeft, getPaddingRight, getPaddingTop, getWidth, isKeepTogether, isKeepWithNext, setHeight, setHeight, setKeepTogether, setKeepWithNext, setMargin, setMarginBottom, setMarginLeft, setMarginRight, setMargins, setMarginTop, setMaxHeight, setMaxHeight, setMaxWidth, setMaxWidth, setMinHeight, setMinHeight, setMinWidth, setMinWidth, setPadding, setPaddingBottom, setPaddingLeft, setPaddingRight, setPaddings, setPaddingTop, setRotationAngle, setRotationAngle, setSpacingRatio, setVerticalAlignment, setWidth, setWidthaddStyle, createRendererSubTree, getChildren, getProperty, getRenderer, hasProperty, isEmpty, setAction, setNextRenderer, setPageNumberdeleteOwnProperty, getOwnProperty, getSplitCharacters, getStrokeColor, getStrokeWidth, getTextRenderingMode, hasOwnProperty, setBackgroundColor, setBackgroundColor, setBackgroundColor, setBackgroundColor, setBackgroundImage, setBackgroundImage, setBaseDirection, setBold, setBorder, setBorderBottom, setBorderBottomLeftRadius, setBorderBottomRightRadius, setBorderLeft, setBorderRadius, setBorderRight, setBorderTop, setBorderTopLeftRadius, setBorderTopRightRadius, setCharacterSpacing, setDestination, setFixedPosition, setFixedPosition, setFixedPosition, setFixedPosition, setFont, setFont, setFontColor, setFontColor, setFontFamily, setFontFamily, setFontKerning, setFontScript, setFontSize, setHorizontalAlignment, setHyphenation, setItalic, setLineThrough, setOpacity, setProperty, setRelativePosition, setSplitCharacters, setStrokeColor, setStrokeWidth, setTextAlignment, setTextRenderingMode, setUnderline, setUnderline, setUnderline, setUnderline, setWordSpacingclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcreateRendererSubTree, getRenderer, setNextRendererdeleteOwnProperty, getOwnProperty, getProperty, hasOwnProperty, hasProperty, setPropertypublic static final String DEFAULT_LIST_SYMBOL
protected DefaultAccessibilityProperties tagProperties
public List()
DEFAULT_LIST_SYMBOL as a prefix.public List(ListNumberingType listNumberingType)
listNumberingType - a prefix stylepublic <T1> T1 getDefaultProperty(int property)
IPropertyContainergetDefaultProperty in interface IPropertyContainergetDefaultProperty in class BlockElement<List>T1 - the return type associated with the propertyproperty - the property to be retrievednull will be returnedpublic List add(ListItem listItem)
ListItem to the bottom of the List.listItem - a new list itempublic List add(String text)
ListItem to the bottom of the List.text - textual contents of the new list itempublic List setItemStartIndex(int start)
start - the custom index, as an intpublic List setListSymbol(String symbol)
list items will be shown with the same prefix.symbol - the textual symbol to be used for all items.public List setListSymbol(Text text)
list items will be shown with the same prefix.text - the Text object to be used for all items.public List setListSymbol(Image image)
list items will be shown with the same prefix.image - the Image object to be used for all items.public List setListSymbol(ListNumberingType listNumberingType)
ListItem will have a unique prefix.listNumberingType - the ListNumberingType that will generate appropriate prefixes for the ListItems.public List setListSymbolAlignment(ListSymbolAlignment alignment)
ListSymbolAlignment.LEFT means that the items will be aligned as follows:
9. Item 9
10. Item 10
Whereas ListSymbolAlignment.RIGHT means the items will be aligned as follows:
9. Item 9
10. Item 10
alignment - the alignment of the list symbolspublic Float getSymbolIndent()
ListItem symbols.float.public List setSymbolIndent(float symbolIndent)
ListItem symbols.symbolIndent - the new indent offset.public String getPostSymbolText()
ListItem symbol.public void setPostSymbolText(String postSymbolText)
ListItem symbol.postSymbolText - the post symbol textpublic String getPreSymbolText()
ListItem symbol.public void setPreSymbolText(String preSymbolText)
ListItem symbol.preSymbolText - the pre symbol textpublic AccessibilityProperties getAccessibilityProperties()
IAccessibleElementaccessibility properties. See also IAccessibleElement.protected IRenderer makeNewRenderer()
makeNewRenderer in class AbstractElement<List>Copyright © 1998–2020 iText Group NV. All rights reserved.