Interface IndexedScrollable

All Known Implementing Classes:
FieldPanel

public interface IndexedScrollable
Interface for scrolling a FieldPanel or container of a group of FieldPanels which displays a list of displayable items (layouts)
  • Method Details

    • getIndexCount

      BigInteger getIndexCount()
      Returns the number individually addressable items displayed.
      Returns:
      the number individually addressable items displayed
    • isUniformIndex

      boolean isUniformIndex()
      Returns true if all the items are the same vertical size.
      Returns:
      true if all the items are the same vertical size
    • getHeight

      int getHeight(BigInteger index)
      Returns the height of the n'th item.
      Parameters:
      index - the index of the time to get height for
      Returns:
      the height of the n'th item.
    • showIndex

      void showIndex(BigInteger index, int verticalOffset)
      Makes the item at the given index be visible on the screen at the given vertical offset
      Parameters:
      index - the index of the item to show
      verticalOffset - the number of pixels from the top of the screen to show the item
    • getIndexAfter

      BigInteger getIndexAfter(BigInteger index)
      Returns the index of the next non-null item. Not all indexes have items. Some items span multiple indexes
      Parameters:
      index - the index to start searching for the next non-null item
      Returns:
      the index of the next non-null item, or -1 if there is none
    • getIndexBefore

      BigInteger getIndexBefore(BigInteger index)
      Returns the index of the previous non-null item. Not all indexes have items. Some items span multiple indexes
      Parameters:
      index - the index to start searching backwards for the previous non-null item
      Returns:
      the index of the previous non-null item, or -1 if there is none
    • scrollLineUp

      void scrollLineUp()
      Scrolls the displayed items up by the height of one line of text
    • scrollLineDown

      void scrollLineDown()
      Scrolls the displayed items down by the height of one line of text
    • scrollPageUp

      void scrollPageUp()
      Scrolls the displayed items up by the height of one screen of text
    • scrollPageDown

      void scrollPageDown()
      Scrolls the displayed items down by the height of one screen of text
    • addIndexScrollListener

      void addIndexScrollListener(IndexScrollListener listener)
      Adds a listener to be notified when the view is scrolled in any way.
      Parameters:
      listener - the listener to be notified when the visible items change
    • removeIndexScrollListener

      void removeIndexScrollListener(IndexScrollListener listener)
      Removes the given listener from those to be notified when the view changes.
      Parameters:
      listener - the listener to remove
    • mouseWheelMoved

      void mouseWheelMoved(double preciseWheelRotation, boolean isHorizontal)
      Notify the scrollable that the mouse wheel was moved.
      Parameters:
      preciseWheelRotation - the amount of rotation of the wheel
      isHorizontal - true if the rotation was horizontal, false for vertical