Package com.teamten.typeset
Class ColumnVerticalList
java.lang.Object
com.teamten.typeset.ElementList
com.teamten.typeset.ColumnVerticalList
- All Implemented Interfaces:
ElementSink
A vertical list of elements that will get broken into columns.
-
Nested Class Summary
Nested classes/interfaces inherited from class com.teamten.typeset.ElementList
ElementList.Breakpoint -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionformatIntoColumns(@NotNull ColumnLayout columnLayout) Takes the list of elements in the vertical list and breaks them into equal-sized columns.protected intgetChunkExtraIncrement(Chunk chunk) When generating breakpoints, if there are images and other things in a chunk, we must adjust the counter if those images will take up space (such as a space).protected longgetElementSize(Element element) Return the size (width for horizontal lists, height + depth for vertical lists) of the element.getElementSublist(ElementList.Breakpoint beginBreakpoint, ElementList.Breakpoint endBreakpoint) Return the list of elements on this line or page.protected BoxmakeOutputBox(List<Element> elements, int counter, long shift) Generate the Box that will be sent to the output.Methods inherited from class com.teamten.typeset.ElementList
addElement, computeStartIndices, findBreakpoints, format, format, getElements, println, reverseRightToLeftText
-
Constructor Details
-
ColumnVerticalList
public ColumnVerticalList()
-
-
Method Details
-
makeOutputBox
Description copied from class:ElementListGenerate the Box that will be sent to the output.- Specified by:
makeOutputBoxin classElementList- Parameters:
elements- the elements of the box.counter- the number of the box, starting from 1. For horizontal lists this is the line number of the paragraph. For vertical lists this is the physical page number.shift- how much to shift the box in the final layout (up or to the right).
-
getElementSize
Description copied from class:ElementListReturn the size (width for horizontal lists, height + depth for vertical lists) of the element.- Specified by:
getElementSizein classElementList
-
getElementSublist
protected List<Element> getElementSublist(ElementList.Breakpoint beginBreakpoint, ElementList.Breakpoint endBreakpoint) Description copied from class:ElementListReturn the list of elements on this line or page. Can process elements to make them more appropriate to this particular range.- Specified by:
getElementSublistin classElementList
-
formatIntoColumns
Takes the list of elements in the vertical list and breaks them into equal-sized columns.- Returns:
- a list of columns (VBox) separated by margins (Glue).
-
getChunkExtraIncrement
Description copied from class:ElementListWhen generating breakpoints, if there are images and other things in a chunk, we must adjust the counter if those images will take up space (such as a space).- Specified by:
getChunkExtraIncrementin classElementList
-