Class List
- All Implemented Interfaces:
IAbstractElement, IBlockElement, IElement, IPropertyContainer, IAccessibleElement
A List is a layout element representing a series of objects that are vertically
outlined with the same or very similar layout properties, giving it a sense
of unity. It contains
ListItem objects that can optionally be prefixed
with a symbol and/or numbered.-
Field Summary
FieldsFields inherited from class AbstractElement
childElements, nextRenderer, stylesFields inherited from class ElementPropertyContainer
properties -
Constructor Summary
ConstructorsConstructorDescriptionList()Creates a List with theDEFAULT_LIST_SYMBOLas a prefix.List(ListNumberingType listNumberingType) Creates a List with a custom numbering type. -
Method Summary
Modifier and TypeMethodDescriptionAdds a newListItemto the bottom of the List.Adds a newListItemto the bottom of the List.Gets theaccessibility properties.<T1> T1getDefaultProperty(int property) Gets the default property from this entity.Gets the piece of text that is added after theListItemsymbol.Gets the piece of text that is added before theListItemsymbol.Gets the indent offset of theListItemsymbols.protected IRendererCreates a new renderer instance.setItemStartIndex(int start) Customizes the index of the first item in the list.setListSymbol(Image image) Sets the list symbol to be used.setListSymbol(Text text) Sets the list symbol to be used.setListSymbol(ListNumberingType listNumberingType) Sets the list numbering type to be used.setListSymbol(String symbol) Sets the list symbol to be used.setListSymbolAlignment(ListSymbolAlignment alignment) A specialized enum containing alignment properties for list symbols.voidsetPostSymbolText(String postSymbolText) Sets a piece of text that should be added after theListItemsymbol.voidsetPreSymbolText(String preSymbolText) Sets a piece of text that should be added before theListItemsymbol.setSymbolIndent(float symbolIndent) Sets the indent offset of theListItemsymbols.Methods inherited from class BlockElement
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, setNeutralRole, setPadding, setPaddingBottom, setPaddingLeft, setPaddingRight, setPaddings, setPaddingTop, setRotationAngle, setRotationAngle, setSpacingRatio, setVerticalAlignment, setWidth, setWidthMethods inherited from class AbstractElement
addStyle, createRendererSubTree, getChildren, getProperty, getRenderer, hasProperty, isEmpty, setAction, setNextRenderer, setPageNumberMethods inherited from class ElementPropertyContainer
deleteOwnProperty, getOwnProperty, getSplitCharacters, getStrokeColor, getStrokeWidth, getTextRenderingMode, getTransparentStrokeColor, hasOwnProperty, setBackgroundColor, setBackgroundColor, setBackgroundColor, setBackgroundColor, setBackgroundImage, setBackgroundImage, setBaseDirection, setBorder, setBorderBottom, setBorderBottomLeftRadius, setBorderBottomRightRadius, setBorderLeft, setBorderRadius, setBorderRight, setBorderTop, setBorderTopLeftRadius, setBorderTopRightRadius, setCharacterSpacing, setDashPattern, setDestination, setFixedPosition, setFixedPosition, setFixedPosition, setFixedPosition, setFont, setFontColor, setFontColor, setFontColor, setFontFamily, setFontFamily, setFontKerning, setFontScript, setFontSize, setHorizontalAlignment, setHyphenation, setLineThrough, setOpacity, setProperty, setRelativePosition, setSplitCharacters, setStrokeColor, setStrokeColor, setStrokeColor, setStrokeWidth, setTextAlignment, setTextRenderingMode, setUnderline, setUnderline, setUnderline, setUnderline, setUnderline, setWordSpacing, simulateBold, simulateItalicMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface IAbstractElement
getChildrenMethods inherited from interface IElement
createRendererSubTree, getRenderer, setNextRendererMethods inherited from interface IPropertyContainer
deleteOwnProperty, getOwnProperty, getProperty, hasOwnProperty, hasProperty, setProperty
-
Field Details
-
DEFAULT_LIST_SYMBOL
- See Also:
-
tagProperties
-
-
Constructor Details
-
List
public List()Creates a List with theDEFAULT_LIST_SYMBOLas a prefix. -
List
Creates a List with a custom numbering type.- Parameters:
listNumberingType- a prefix style
-
-
Method Details
-
getDefaultProperty
public <T1> T1 getDefaultProperty(int property) Description copied from interface:IPropertyContainerGets the default property from this entity.- Specified by:
getDefaultPropertyin interfaceIPropertyContainer- Overrides:
getDefaultPropertyin classBlockElement<List>- Type Parameters:
T1- the return type associated with the property- Parameters:
property- the property to be retrieved- Returns:
- the default property value. If the default property is not defined,
nullwill be returned
-
add
-
add
-
setItemStartIndex
Customizes the index of the first item in the list.- Parameters:
start- the custom index, as anint- Returns:
- this list.
-
setListSymbol
Sets the list symbol to be used. This will create an unordered list, i.e. alllist itemswill be shown with the same prefix.- Parameters:
symbol- the textual symbol to be used for all items.- Returns:
- this list.
-
setListSymbol
Sets the list symbol to be used. This will create an unordered list, i.e. alllist itemswill be shown with the same prefix.- Parameters:
text- theTextobject to be used for all items.- Returns:
- this list.
-
setListSymbol
Sets the list symbol to be used. This will create an unordered list, i.e. alllist itemswill be shown with the same prefix.- Parameters:
image- theImageobject to be used for all items.- Returns:
- this list.
-
setListSymbol
Sets the list numbering type to be used. This will create an ordered list, i.e. everyListItemwill have a unique prefix.- Parameters:
listNumberingType- theListNumberingTypethat will generate appropriate prefixes for theListItems.- Returns:
- this list.
-
setListSymbolAlignment
A specialized enum containing alignment properties for list symbols.ListSymbolAlignment.LEFTmeans that the items will be aligned as follows: 9. Item 9 10. Item 10Whereas
ListSymbolAlignment.RIGHTmeans the items will be aligned as follows: 9. Item 9 10. Item 10- Parameters:
alignment- the alignment of the list symbols- Returns:
- this element
-
getSymbolIndent
-
setSymbolIndent
-
getPostSymbolText
-
setPostSymbolText
-
getPreSymbolText
-
setPreSymbolText
-
getAccessibilityProperties
Description copied from interface:IAccessibleElementGets theaccessibility properties. See alsoIAccessibleElement.- Returns:
- an interface that allows to specify properties of a tagged element in Tagged PDF.
-
makeNewRenderer
Description copied from class:AbstractElementCreates a new renderer instance.- Specified by:
makeNewRendererin classAbstractElement<List>- Returns:
- new
IRenderer
-