content
The content of the gui, to be displayed on the lines.
C
- The content type.Gui
Only in very rare circumstances should this class be used directly.
Instead, use the static factory or builder functions from the ScrollGui
interface,
such as ScrollGui.items()
, ScrollGui.guis()
or ScrollGui.inventories()
to create a new ScrollGui
.
Gui.Builder<G extends Gui,S extends Gui.Builder<G,S>>
ScrollGui.Builder<C>
protected List<SlotElement>
SlotElements
, containing the content.AbstractScrollGui(int width,
int height,
boolean infiniteLines,
int... contentListSlots)
AbstractScrollGui
.AbstractScrollGui(int width,
int height,
boolean infiniteLines,
Structure structure)
AbstractScrollGui
.void
addScrollHandler(@NotNull BiConsumer<Integer,Integer> scrollHandler)
ScrollGui
.boolean
canScroll(int lines)
int
ScrollGui
.int
AbstractScrollGui
.int
ScrollGui
.void
removeScrollHandler(@NotNull BiConsumer<Integer,Integer> scrollHandler)
ScrollGui
.void
scroll(int lines)
void
setContent(@Nullable List<C> content)
ScrollGui
for all lines.void
setCurrentLine(int line)
ScrollGui
.void
setScrollHandlers(@NotNull List<@NotNull BiConsumer<Integer,Integer>> scrollHandlers)
protected void
update()
addItems, addParent, addSlotElements, applyStructure, cancelAnimation, closeForAllViewers, fill, fill, fillBorders, fillColumn, fillRectangle, fillRectangle, fillRectangle, fillRectangle, fillRow, findAllCurrentViewers, findAllWindows, getAllInventories, getAllInventorySlots, getBackground, getHeight, getItem, getItem, getParents, getSize, getSlotElement, getSlotElement, getSlotElements, getWidth, handleClick, handleInvDoubleClick, handleInvDrop, handleInvItemShift, handleInvLeftClick, handleInvMiddleClick, handleInvNumberKey, handleInvOffHandKey, handleInvRightClick, handleInvSlotElementClick, handleItemDrag, handleItemShift, handleSlotElementUpdate, hasSlotElement, hasSlotElement, isFrozen, isIgnoreObscuredInventorySlots, playAnimation, putIntoFirstInventory, remove, remove, removeParent, setBackground, setFrozen, setIgnoreObscuredInventorySlots, setItem, setItem, setSlotElement, setSlotElement, updateControlItems
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addItems, addSlotElements, applyStructure, cancelAnimation, closeForAllViewers, fill, fill, fillBorders, fillColumn, fillRectangle, fillRectangle, fillRectangle, fillRectangle, fillRow, findAllCurrentViewers, findAllWindows, getBackground, getHeight, getItem, getItem, getSize, getSlotElement, getSlotElement, getSlotElements, getWidth, hasSlotElement, hasSlotElement, isFrozen, isIgnoreObscuredInventorySlots, playAnimation, remove, remove, setBackground, setFrozen, setIgnoreObscuredInventorySlots, setItem, setItem, setSlotElement, setSlotElement
SlotElements
, containing the content.AbstractScrollGui
.width
- The width of the gui.height
- The height of the gui.infiniteLines
- Whether the gui has infinite lines.contentListSlots
- The slots to be used for lines.AbstractScrollGui
.width
- The width of the gui.height
- The height of the gui.infiniteLines
- Whether the gui has infinite lines.structure
- The structure of the gui.AbstractScrollGui
.ScrollGui
ScrollGui
.getCurrentLine
in interface ScrollGui<C>
ScrollGui
.ScrollGui
ScrollGui
.setCurrentLine
in interface ScrollGui<C>
line
- The line to set.ScrollGui
ScrollGui
ScrollGui
ScrollGui
.getMaxLine
in interface ScrollGui<C>
ScrollGui
.ScrollGui
ScrollGui
for all lines.setContent
in interface ScrollGui<C>
content
- The content to set.ScrollGui
setScrollHandlers
in interface ScrollGui<C>
scrollHandlers
- The new scroll handlers.ScrollGui
ScrollGui
.addScrollHandler
in interface ScrollGui<C>
scrollHandler
- The scroll handler to add.ScrollGui
ScrollGui
.removeScrollHandler
in interface ScrollGui<C>
scrollHandler
- The scroll handler to remove.