Class ListSpinner<T>

java.lang.Object
javafx.scene.Node
javafx.scene.Parent
javafx.scene.layout.Region
javafx.scene.control.Control
jfxtras.scene.control.ListSpinner<T>
All Implemented Interfaces:
javafx.css.Styleable, javafx.event.EventTarget, javafx.scene.control.Skinnable

public class ListSpinner<T> extends javafx.scene.control.Control
This is a spinner, showing one value at a time from a list. This value is set and retrieved through the value property. Basically a spinner shows a list of values and can do a "next" or "previous". A spinner can be editable, the user can then type a value instead of selecting it. If the value exists in the list, the spinner will simply jump to it. If the value does not exist, the AddCallback is called if defined. - If the AddCallback returns null, spinner will only refresh the current index. - If the AddCallback returns an Integer, spinner will jump to that index (usually the index where the new value was added to the list). ''' In the default skin you can style the text in the control using CSS like so: [source,css] -- .ListSpinner .value { -fx-font-weight: bold; } -- The "value" class applies to the text in both readonly and editable spinners, use the "readonly" or "editable" class to style either mode specifically. There is a left-arrow, right-arrow, up-arrow and down-arrow class that uses a SVG path to draw the arrow, this can be overridden with another SVG to draw a different shape. The default skin has a number of styleable properies which use the text representation of an enum for their value: [source,css] -- .ListSpinner { -fxx-arrow-position: {LEADING, TRAILING, SPLIT} -fxx-arrow-direction: {VERTICAL, HORIZONTAL} -fxx-value-alignment: see javafx.geometry.Pos (https://docs.oracle.com/javase/8/javafx/api/javafx/geometry/Pos.html) } --
  • Property Summary

    Properties
    Type
    Property
    Description
    javafx.beans.property.ObjectProperty<javafx.util.Callback<T,Integer>>
    AddCallback: this callback is called in editable mode when a value is entered that is not found in the list.
    javafx.beans.property.ObjectProperty<javafx.util.Callback<ListSpinner<T>,javafx.scene.Node>>
    CellFactory: generate the cell to render a value
    javafx.beans.property.ObjectProperty<Boolean>
    Cyclic: what happens at the beginning or end of the list, stop or cycle to the other end.
    javafx.beans.property.ObjectProperty<Boolean>
    Editable: is the listspinner editable.
    javafx.beans.property.ObjectProperty<Integer>
    Index: the currently show index in the list.
    javafx.beans.property.ObjectProperty<javafx.collections.ObservableList<T>>
    Items: the list.
    javafx.beans.property.ObjectProperty<javafx.event.EventHandler<ListSpinner.CycleEvent>>
    OnCycle: callback for when the list cycles to the other end in cyclic mode (for example to increase a year when a month ListSpinner skips from December to January)
    javafx.beans.property.ObjectProperty<String>
    Postfix: a string to be placed after the value, this can for example be a unit like "kg"
    javafx.beans.property.ObjectProperty<String>
    Prefix: a string to be placed before the list value, this can for example be a currency
    javafx.beans.property.ObjectProperty<javafx.util.StringConverter<T>>
    StringConverter<T>: convert a value in the list to its string representation and (when in edit mode) vice versa.
    javafx.beans.property.ObjectProperty<T>
    Value: the currently show value of the list.

    Properties inherited from class javafx.scene.control.Control

    contextMenu, skin, tooltip

    Properties inherited from class javafx.scene.layout.Region

    background, border, cacheShape, centerShape, height, insets, maxHeight, maxWidth, minHeight, minWidth, opaqueInsets, padding, prefHeight, prefWidth, scaleShape, shape, snapToPixel, width

    Properties inherited from class javafx.scene.Parent

    needsLayout

    Properties inherited from class javafx.scene.Node

    accessibleHelp, accessibleRoleDescription, accessibleRole, accessibleText, blendMode, boundsInLocal, boundsInParent, cacheHint, cache, clip, cursor, depthTest, disabled, disable, effectiveNodeOrientation, effect, eventDispatcher, focused, focusTraversable, hover, id, inputMethodRequests, layoutBounds, layoutX, layoutY, localToParentTransform, localToSceneTransform, managed, mouseTransparent, nodeOrientation, onContextMenuRequested, onDragDetected, onDragDone, onDragDropped, onDragEntered, onDragExited, onDragOver, onInputMethodTextChanged, onKeyPressed, onKeyReleased, onKeyTyped, onMouseClicked, onMouseDragEntered, onMouseDragExited, onMouseDragged, onMouseDragOver, onMouseDragReleased, onMouseEntered, onMouseExited, onMouseMoved, onMousePressed, onMouseReleased, onRotate, onRotationFinished, onRotationStarted, onScrollFinished, onScroll, onScrollStarted, onSwipeDown, onSwipeLeft, onSwipeRight, onSwipeUp, onTouchMoved, onTouchPressed, onTouchReleased, onTouchStationary, onZoomFinished, onZoom, onZoomStarted, opacity, parent, pickOnBounds, pressed, rotate, rotationAxis, scaleX, scaleY, scaleZ, scene, style, translateX, translateY, translateZ, viewOrder, visible
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static enum 
     
    static class 
    CycleEvent
    (package private) class 
    Default cell factory
    (package private) class 
    A string converter that does a simple toString, but cannot convert to an object
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private final javafx.beans.property.ObjectProperty<javafx.util.Callback<T,Integer>>
     
    private final javafx.beans.property.ObjectProperty<javafx.util.Callback<ListSpinner<T>,javafx.scene.Node>>
     
    private final javafx.beans.property.ObjectProperty<Boolean>
     
    private final javafx.beans.property.ObjectProperty<Boolean>
     
    private final javafx.beans.property.ObjectProperty<Integer>
     
    private final javafx.beans.property.ObjectProperty<javafx.event.EventHandler<ListSpinner.CycleEvent>>
     
    private final javafx.beans.property.ObjectProperty<javafx.collections.ObservableList<T>>
     
    private javafx.collections.ListChangeListener<T>
     
    static final String
     
    private final javafx.beans.property.ObjectProperty<String>
     
    private final javafx.beans.property.ObjectProperty<String>
     
    private final javafx.beans.property.ObjectProperty<javafx.util.StringConverter<T>>
     
    private final javafx.beans.property.ObjectProperty<T>
     

    Fields inherited from class javafx.scene.layout.Region

    USE_COMPUTED_SIZE, USE_PREF_SIZE

    Fields inherited from class javafx.scene.Node

    BASELINE_OFFSET_SAME_AS_HEIGHT
  • Constructor Summary

    Constructors
    Constructor
    Description
     
    ListSpinner(int from, int to)
     
    ListSpinner(int from, int to, int step)
     
     
    ListSpinner(javafx.collections.ObservableList<T> items)
     
    ListSpinner(javafx.collections.ObservableList<T> items, T startValue)
     
    ListSpinner(T... list)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    javafx.beans.property.ObjectProperty<javafx.util.Callback<T,Integer>>
    AddCallback: this callback is called in editable mode when a value is entered that is not found in the list.
    javafx.beans.property.ObjectProperty<javafx.util.Callback<ListSpinner<T>,javafx.scene.Node>>
    CellFactory: generate the cell to render a value
    private void
     
    javafx.scene.control.Skin<?>
     
    javafx.beans.property.ObjectProperty<Boolean>
    Cyclic: what happens at the beginning or end of the list, stop or cycle to the other end.
    void
     
    javafx.beans.property.ObjectProperty<Boolean>
    Editable: is the listspinner editable.
    static boolean
    equals(Object o1, Object o2)
    Does a o1.equals(o2) but also checks if o1 or o2 are null.
    void
    we're cycling, fire the event
    void
     
    javafx.util.Callback<T,Integer>
    Gets the value of the property addCallback.
    javafx.util.Callback<ListSpinner<T>,javafx.scene.Node>
    Gets the value of the property cellFactory.
    Gets the value of the property index.
    javafx.collections.ObservableList<T>
    Gets the value of the property items.
    javafx.event.EventHandler<ListSpinner.CycleEvent>
    Gets the value of the property onCycle.
    Gets the value of the property postfix.
    Gets the value of the property prefix.
    javafx.util.StringConverter<T>
    Gets the value of the property stringConverter.
    Return the path to the CSS file so things are setup right
    Gets the value of the property value.
    void
     
    javafx.beans.property.ObjectProperty<Integer>
    Index: the currently show index in the list.
     
     
    javafx.beans.property.ObjectProperty<javafx.collections.ObservableList<T>>
    Items: the list.
    void
    Get the last index; if the data provide is endless, this method mail fail!
    javafx.beans.property.ObjectProperty<javafx.event.EventHandler<ListSpinner.CycleEvent>>
    OnCycle: callback for when the list cycles to the other end in cyclic mode (for example to increase a year when a month ListSpinner skips from December to January)
    javafx.beans.property.ObjectProperty<String>
    Postfix: a string to be placed after the value, this can for example be a unit like "kg"
    javafx.beans.property.ObjectProperty<String>
    Prefix: a string to be placed before the list value, this can for example be a currency
    void
    setAddCallback(javafx.util.Callback<T,Integer> value)
    Sets the value of the property addCallback.
    void
    setCellFactory(javafx.util.Callback<ListSpinner<T>,javafx.scene.Node> value)
    Sets the value of the property cellFactory.
    void
    Sets the value of the property cyclic.
    void
    Sets the value of the property editable.
    void
    Sets the value of the property index.
    void
    setItems(javafx.collections.ObservableList<T> value)
    Sets the value of the property items.
    void
    setOnCycle(javafx.event.EventHandler<ListSpinner.CycleEvent> value)
    Sets the value of the property onCycle.
    void
    Sets the value of the property postfix.
    void
    Sets the value of the property prefix.
    void
    setStringConverter(javafx.util.StringConverter<T> value)
    Sets the value of the property stringConverter.
    void
    setValue(T value)
    Sets the value of the property value.
    javafx.beans.property.ObjectProperty<javafx.util.StringConverter<T>>
    StringConverter<T>: convert a value in the list to its string representation and (when in edit mode) vice versa.
    javafx.beans.property.ObjectProperty<T>
    Value: the currently show value of the list.
    withAddCallback(javafx.util.Callback<T,Integer> value)
     
    withCellFactory(javafx.util.Callback<ListSpinner<T>,javafx.scene.Node> value)
     
     
     
    withId(String value)
    Id
     
    withItems(javafx.collections.ObservableList<T> value)
     
    withOnCycle(javafx.event.EventHandler<ListSpinner.CycleEvent> value)
     
     
     
    withStringConverter(javafx.util.StringConverter<T> value)
     
    withValue(T value)
     

    Methods inherited from class javafx.scene.control.Control

    computeMaxHeight, computeMaxWidth, computeMinHeight, computeMinWidth, computePrefHeight, computePrefWidth, contextMenuProperty, executeAccessibleAction, getBaselineOffset, getClassCssMetaData, getContextMenu, getControlCssMetaData, getCssMetaData, getInitialFocusTraversable, getSkin, getTooltip, isResizable, layoutChildren, queryAccessibleAttribute, setContextMenu, setSkin, setTooltip, skinProperty, tooltipProperty

    Methods inherited from class javafx.scene.layout.Region

    backgroundProperty, borderProperty, cacheShapeProperty, centerShapeProperty, getBackground, getBorder, getHeight, getInsets, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getOpaqueInsets, getPadding, getPrefHeight, getPrefWidth, getShape, getWidth, heightProperty, insetsProperty, isCacheShape, isCenterShape, isScaleShape, isSnapToPixel, layoutInArea, layoutInArea, layoutInArea, layoutInArea, maxHeight, maxHeightProperty, maxWidth, maxWidthProperty, minHeight, minHeightProperty, minWidth, minWidthProperty, opaqueInsetsProperty, paddingProperty, positionInArea, positionInArea, prefHeight, prefHeightProperty, prefWidth, prefWidthProperty, resize, scaleShapeProperty, setBackground, setBorder, setCacheShape, setCenterShape, setHeight, setMaxHeight, setMaxSize, setMaxWidth, setMinHeight, setMinSize, setMinWidth, setOpaqueInsets, setPadding, setPrefHeight, setPrefSize, setPrefWidth, setScaleShape, setShape, setSnapToPixel, setWidth, shapeProperty, snappedBottomInset, snappedLeftInset, snappedRightInset, snappedTopInset, snapPosition, snapPositionX, snapPositionY, snapSize, snapSizeX, snapSizeY, snapSpace, snapSpaceX, snapSpaceY, snapToPixelProperty, widthProperty

    Methods inherited from class javafx.scene.Parent

    getChildren, getChildrenUnmodifiable, getManagedChildren, getStylesheets, isNeedsLayout, layout, lookup, needsLayoutProperty, requestLayout, requestParentLayout, setNeedsLayout, updateBounds

    Methods inherited from class javafx.scene.Node

    accessibleHelpProperty, accessibleRoleDescriptionProperty, accessibleRoleProperty, accessibleTextProperty, addEventFilter, addEventHandler, applyCss, autosize, blendModeProperty, boundsInLocalProperty, boundsInParentProperty, buildEventDispatchChain, cacheHintProperty, cacheProperty, clipProperty, computeAreaInScreen, contains, contains, cursorProperty, depthTestProperty, disabledProperty, disableProperty, effectiveNodeOrientationProperty, effectProperty, eventDispatcherProperty, fireEvent, focusedProperty, focusTraversableProperty, getAccessibleHelp, getAccessibleRole, getAccessibleRoleDescription, getAccessibleText, getBlendMode, getBoundsInLocal, getBoundsInParent, getCacheHint, getClip, getContentBias, getCursor, getDepthTest, getEffect, getEffectiveNodeOrientation, getEventDispatcher, getId, getInitialCursor, getInputMethodRequests, getLayoutBounds, getLayoutX, getLayoutY, getLocalToParentTransform, getLocalToSceneTransform, getNodeOrientation, getOnContextMenuRequested, getOnDragDetected, getOnDragDone, getOnDragDropped, getOnDragEntered, getOnDragExited, getOnDragOver, getOnInputMethodTextChanged, getOnKeyPressed, getOnKeyReleased, getOnKeyTyped, getOnMouseClicked, getOnMouseDragEntered, getOnMouseDragExited, getOnMouseDragged, getOnMouseDragOver, getOnMouseDragReleased, getOnMouseEntered, getOnMouseExited, getOnMouseMoved, getOnMousePressed, getOnMouseReleased, getOnRotate, getOnRotationFinished, getOnRotationStarted, getOnScroll, getOnScrollFinished, getOnScrollStarted, getOnSwipeDown, getOnSwipeLeft, getOnSwipeRight, getOnSwipeUp, getOnTouchMoved, getOnTouchPressed, getOnTouchReleased, getOnTouchStationary, getOnZoom, getOnZoomFinished, getOnZoomStarted, getOpacity, getParent, getProperties, getPseudoClassStates, getRotate, getRotationAxis, getScaleX, getScaleY, getScaleZ, getScene, getStyle, getStyleableParent, getStyleClass, getTransforms, getTranslateX, getTranslateY, getTranslateZ, getTypeSelector, getUserData, getViewOrder, hasProperties, hoverProperty, idProperty, inputMethodRequestsProperty, intersects, intersects, isCache, isDisable, isDisabled, isFocused, isFocusTraversable, isHover, isManaged, isMouseTransparent, isPickOnBounds, isPressed, isVisible, layoutBoundsProperty, layoutXProperty, layoutYProperty, localToParent, localToParent, localToParent, localToParent, localToParent, localToParentTransformProperty, localToScene, localToScene, localToScene, localToScene, localToScene, localToScene, localToScene, localToScene, localToScene, localToScene, localToSceneTransformProperty, localToScreen, localToScreen, localToScreen, localToScreen, localToScreen, lookupAll, managedProperty, mouseTransparentProperty, nodeOrientationProperty, notifyAccessibleAttributeChanged, onContextMenuRequestedProperty, onDragDetectedProperty, onDragDoneProperty, onDragDroppedProperty, onDragEnteredProperty, onDragExitedProperty, onDragOverProperty, onInputMethodTextChangedProperty, onKeyPressedProperty, onKeyReleasedProperty, onKeyTypedProperty, onMouseClickedProperty, onMouseDragEnteredProperty, onMouseDragExitedProperty, onMouseDraggedProperty, onMouseDragOverProperty, onMouseDragReleasedProperty, onMouseEnteredProperty, onMouseExitedProperty, onMouseMovedProperty, onMousePressedProperty, onMouseReleasedProperty, onRotateProperty, onRotationFinishedProperty, onRotationStartedProperty, onScrollFinishedProperty, onScrollProperty, onScrollStartedProperty, onSwipeDownProperty, onSwipeLeftProperty, onSwipeRightProperty, onSwipeUpProperty, onTouchMovedProperty, onTouchPressedProperty, onTouchReleasedProperty, onTouchStationaryProperty, onZoomFinishedProperty, onZoomProperty, onZoomStartedProperty, opacityProperty, parentProperty, parentToLocal, parentToLocal, parentToLocal, parentToLocal, parentToLocal, pickOnBoundsProperty, pressedProperty, pseudoClassStateChanged, relocate, removeEventFilter, removeEventHandler, requestFocus, resizeRelocate, rotateProperty, rotationAxisProperty, scaleXProperty, scaleYProperty, scaleZProperty, sceneProperty, sceneToLocal, sceneToLocal, sceneToLocal, sceneToLocal, sceneToLocal, sceneToLocal, sceneToLocal, sceneToLocal, screenToLocal, screenToLocal, screenToLocal, setAccessibleHelp, setAccessibleRole, setAccessibleRoleDescription, setAccessibleText, setBlendMode, setCache, setCacheHint, setClip, setCursor, setDepthTest, setDisable, setDisabled, setEffect, setEventDispatcher, setEventHandler, setFocused, setFocusTraversable, setHover, setId, setInputMethodRequests, setLayoutX, setLayoutY, setManaged, setMouseTransparent, setNodeOrientation, setOnContextMenuRequested, setOnDragDetected, setOnDragDone, setOnDragDropped, setOnDragEntered, setOnDragExited, setOnDragOver, setOnInputMethodTextChanged, setOnKeyPressed, setOnKeyReleased, setOnKeyTyped, setOnMouseClicked, setOnMouseDragEntered, setOnMouseDragExited, setOnMouseDragged, setOnMouseDragOver, setOnMouseDragReleased, setOnMouseEntered, setOnMouseExited, setOnMouseMoved, setOnMousePressed, setOnMouseReleased, setOnRotate, setOnRotationFinished, setOnRotationStarted, setOnScroll, setOnScrollFinished, setOnScrollStarted, setOnSwipeDown, setOnSwipeLeft, setOnSwipeRight, setOnSwipeUp, setOnTouchMoved, setOnTouchPressed, setOnTouchReleased, setOnTouchStationary, setOnZoom, setOnZoomFinished, setOnZoomStarted, setOpacity, setPickOnBounds, setPressed, setRotate, setRotationAxis, setScaleX, setScaleY, setScaleZ, setStyle, setTranslateX, setTranslateY, setTranslateZ, setUserData, setViewOrder, setVisible, snapshot, snapshot, startDragAndDrop, startFullDrag, styleProperty, toBack, toFront, toString, translateXProperty, translateYProperty, translateZProperty, usesMirroring, viewOrderProperty, visibleProperty

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface javafx.css.Styleable

    getStyleableNode
  • Property Details

    • value

      public javafx.beans.property.ObjectProperty<T> valueProperty
      Value: the currently show value of the list.
      See Also:
    • index

      public javafx.beans.property.ObjectProperty<Integer> indexProperty
      Index: the currently show index in the list.
      See Also:
    • cyclic

      public javafx.beans.property.ObjectProperty<Boolean> cyclicProperty
      Cyclic: what happens at the beginning or end of the list, stop or cycle to the other end.
      See Also:
    • editable

      public javafx.beans.property.ObjectProperty<Boolean> editableProperty
      Editable: is the listspinner editable. It allows the user to type a value instead of only navigating to it, and if the AddCallback is defined, possibly also adding values.
      See Also:
    • postfix

      public javafx.beans.property.ObjectProperty<String> postfixProperty
      Postfix: a string to be placed after the value, this can for example be a unit like "kg"
      See Also:
    • prefix

      public javafx.beans.property.ObjectProperty<String> prefixProperty
      Prefix: a string to be placed before the list value, this can for example be a currency
      See Also:
    • items

      public javafx.beans.property.ObjectProperty<javafx.collections.ObservableList<T>> itemsProperty
      Items: the list.
      See Also:
    • cellFactory

      public javafx.beans.property.ObjectProperty<javafx.util.Callback<ListSpinner<T>,javafx.scene.Node>> cellFactoryProperty
      CellFactory: generate the cell to render a value
      See Also:
    • stringConverter

      public javafx.beans.property.ObjectProperty<javafx.util.StringConverter<T>> stringConverterProperty
      StringConverter<T>: convert a value in the list to its string representation and (when in edit mode) vice versa.
      See Also:
    • addCallback

      public javafx.beans.property.ObjectProperty<javafx.util.Callback<T,Integer>> addCallbackProperty
      AddCallback: this callback is called in editable mode when a value is entered that is not found in the list. It is up to the coder to added it to the list or not.
      See Also:
    • onCycle

      public javafx.beans.property.ObjectProperty<javafx.event.EventHandler<ListSpinner.CycleEvent>> onCycleProperty
      OnCycle: callback for when the list cycles to the other end in cyclic mode (for example to increase a year when a month ListSpinner skips from December to January)
      See Also:
  • Field Details

    • listChangeListener

      private javafx.collections.ListChangeListener<T> listChangeListener
    • valueObjectProperty

      private final javafx.beans.property.ObjectProperty<T> valueObjectProperty
    • indexObjectProperty

      private final javafx.beans.property.ObjectProperty<Integer> indexObjectProperty
    • cyclicObjectProperty

      private final javafx.beans.property.ObjectProperty<Boolean> cyclicObjectProperty
    • editableObjectProperty

      private final javafx.beans.property.ObjectProperty<Boolean> editableObjectProperty
    • postfixObjectProperty

      private final javafx.beans.property.ObjectProperty<String> postfixObjectProperty
    • prefixObjectProperty

      private final javafx.beans.property.ObjectProperty<String> prefixObjectProperty
    • itemsObjectProperty

      private final javafx.beans.property.ObjectProperty<javafx.collections.ObservableList<T>> itemsObjectProperty
    • cellFactoryObjectProperty

      private final javafx.beans.property.ObjectProperty<javafx.util.Callback<ListSpinner<T>,javafx.scene.Node>> cellFactoryObjectProperty
    • stringConverterObjectProperty

      private final javafx.beans.property.ObjectProperty<javafx.util.StringConverter<T>> stringConverterObjectProperty
    • addCallbackObjectProperty

      private final javafx.beans.property.ObjectProperty<javafx.util.Callback<T,Integer>> addCallbackObjectProperty
    • iOnCycleObjectProperty

      private final javafx.beans.property.ObjectProperty<javafx.event.EventHandler<ListSpinner.CycleEvent>> iOnCycleObjectProperty
    • ONCYCLE_PROPERTY_ID

      public static final String ONCYCLE_PROPERTY_ID
      See Also:
  • Constructor Details

    • ListSpinner

      public ListSpinner()
    • ListSpinner

      public ListSpinner(javafx.collections.ObservableList<T> items)
      Parameters:
      items - The item list used to populate the spinner.
    • ListSpinner

      public ListSpinner(javafx.collections.ObservableList<T> items, T startValue)
      Parameters:
      items - The item list used to populate the spinner.
      startValue - The initial value of the spinner (one of the items).
    • ListSpinner

      public ListSpinner(List<T> list)
      Parameters:
      list -
    • ListSpinner

      public ListSpinner(T... list)
      Parameters:
      list -
    • ListSpinner

      public ListSpinner(int from, int to)
      Parameters:
      from -
      to -
    • ListSpinner

      public ListSpinner(int from, int to, int step)
      Parameters:
      from -
      to -
      step -
  • Method Details

    • construct

      private void construct()
    • getUserAgentStylesheet

      public String getUserAgentStylesheet()
      Return the path to the CSS file so things are setup right
      Overrides:
      getUserAgentStylesheet in class javafx.scene.layout.Region
    • createDefaultSkin

      public javafx.scene.control.Skin<?> createDefaultSkin()
      Overrides:
      createDefaultSkin in class javafx.scene.control.Control
    • withId

      public ListSpinner<T> withId(String value)
      Id
    • valueProperty

      public javafx.beans.property.ObjectProperty<T> valueProperty()
      Value: the currently show value of the list.
      See Also:
    • getValue

      public T getValue()
      Gets the value of the property value.
      Property description:
      Value: the currently show value of the list.
    • setValue

      public void setValue(T value)
      Sets the value of the property value.
      Property description:
      Value: the currently show value of the list.
    • withValue

      public ListSpinner<T> withValue(T value)
    • indexProperty

      public javafx.beans.property.ObjectProperty<Integer> indexProperty()
      Index: the currently show index in the list.
      See Also:
    • getIndex

      public Integer getIndex()
      Gets the value of the property index.
      Property description:
      Index: the currently show index in the list.
    • setIndex

      public void setIndex(Integer value)
      Sets the value of the property index.
      Property description:
      Index: the currently show index in the list.
    • withIndex

      public ListSpinner<T> withIndex(Integer value)
    • cyclicProperty

      public javafx.beans.property.ObjectProperty<Boolean> cyclicProperty()
      Cyclic: what happens at the beginning or end of the list, stop or cycle to the other end.
      See Also:
    • isCyclic

      public Boolean isCyclic()
    • setCyclic

      public void setCyclic(Boolean value)
      Sets the value of the property cyclic.
      Property description:
      Cyclic: what happens at the beginning or end of the list, stop or cycle to the other end.
    • withCyclic

      public ListSpinner<T> withCyclic(Boolean value)
    • editableProperty

      public javafx.beans.property.ObjectProperty<Boolean> editableProperty()
      Editable: is the listspinner editable. It allows the user to type a value instead of only navigating to it, and if the AddCallback is defined, possibly also adding values.
      See Also:
    • isEditable

      public Boolean isEditable()
    • setEditable

      public void setEditable(Boolean value)
      Sets the value of the property editable.
      Property description:
      Editable: is the listspinner editable. It allows the user to type a value instead of only navigating to it, and if the AddCallback is defined, possibly also adding values.
    • withEditable

      public ListSpinner<T> withEditable(Boolean value)
    • postfixProperty

      public javafx.beans.property.ObjectProperty<String> postfixProperty()
      Postfix: a string to be placed after the value, this can for example be a unit like "kg"
      See Also:
    • getPostfix

      public String getPostfix()
      Gets the value of the property postfix.
      Property description:
      Postfix: a string to be placed after the value, this can for example be a unit like "kg"
    • setPostfix

      public void setPostfix(String value)
      Sets the value of the property postfix.
      Property description:
      Postfix: a string to be placed after the value, this can for example be a unit like "kg"
    • withPostfix

      public ListSpinner<T> withPostfix(String value)
    • prefixProperty

      public javafx.beans.property.ObjectProperty<String> prefixProperty()
      Prefix: a string to be placed before the list value, this can for example be a currency
      See Also:
    • getPrefix

      public String getPrefix()
      Gets the value of the property prefix.
      Property description:
      Prefix: a string to be placed before the list value, this can for example be a currency
    • setPrefix

      public void setPrefix(String value)
      Sets the value of the property prefix.
      Property description:
      Prefix: a string to be placed before the list value, this can for example be a currency
    • withPrefix

      public ListSpinner<T> withPrefix(String value)
    • itemsProperty

      public javafx.beans.property.ObjectProperty<javafx.collections.ObservableList<T>> itemsProperty()
      Items: the list.
      See Also:
    • getItems

      public javafx.collections.ObservableList<T> getItems()
      Gets the value of the property items.
      Property description:
      Items: the list.
    • setItems

      public void setItems(javafx.collections.ObservableList<T> value)
      Sets the value of the property items.
      Property description:
      Items: the list.
    • withItems

      public ListSpinner<T> withItems(javafx.collections.ObservableList<T> value)
    • cellFactoryProperty

      public javafx.beans.property.ObjectProperty<javafx.util.Callback<ListSpinner<T>,javafx.scene.Node>> cellFactoryProperty()
      CellFactory: generate the cell to render a value
      See Also:
    • getCellFactory

      public javafx.util.Callback<ListSpinner<T>,javafx.scene.Node> getCellFactory()
      Gets the value of the property cellFactory.
      Property description:
      CellFactory: generate the cell to render a value
    • setCellFactory

      public void setCellFactory(javafx.util.Callback<ListSpinner<T>,javafx.scene.Node> value)
      Sets the value of the property cellFactory.
      Property description:
      CellFactory: generate the cell to render a value
    • withCellFactory

      public ListSpinner<T> withCellFactory(javafx.util.Callback<ListSpinner<T>,javafx.scene.Node> value)
    • stringConverterProperty

      public javafx.beans.property.ObjectProperty<javafx.util.StringConverter<T>> stringConverterProperty()
      StringConverter<T>: convert a value in the list to its string representation and (when in edit mode) vice versa.
      See Also:
    • getStringConverter

      public javafx.util.StringConverter<T> getStringConverter()
      Gets the value of the property stringConverter.
      Property description:
      StringConverter<T>: convert a value in the list to its string representation and (when in edit mode) vice versa.
    • setStringConverter

      public void setStringConverter(javafx.util.StringConverter<T> value)
      Sets the value of the property stringConverter.
      Property description:
      StringConverter<T>: convert a value in the list to its string representation and (when in edit mode) vice versa.
    • withStringConverter

      public ListSpinner<T> withStringConverter(javafx.util.StringConverter<T> value)
    • addCallbackProperty

      public javafx.beans.property.ObjectProperty<javafx.util.Callback<T,Integer>> addCallbackProperty()
      AddCallback: this callback is called in editable mode when a value is entered that is not found in the list. It is up to the coder to added it to the list or not.
      See Also:
    • getAddCallback

      public javafx.util.Callback<T,Integer> getAddCallback()
      Gets the value of the property addCallback.
      Property description:
      AddCallback: this callback is called in editable mode when a value is entered that is not found in the list. It is up to the coder to added it to the list or not.
    • setAddCallback

      public void setAddCallback(javafx.util.Callback<T,Integer> value)
      Sets the value of the property addCallback.
      Property description:
      AddCallback: this callback is called in editable mode when a value is entered that is not found in the list. It is up to the coder to added it to the list or not.
    • withAddCallback

      public ListSpinner<T> withAddCallback(javafx.util.Callback<T,Integer> value)
    • onCycleProperty

      public javafx.beans.property.ObjectProperty<javafx.event.EventHandler<ListSpinner.CycleEvent>> onCycleProperty()
      OnCycle: callback for when the list cycles to the other end in cyclic mode (for example to increase a year when a month ListSpinner skips from December to January)
      See Also:
    • getOnCycle

      public javafx.event.EventHandler<ListSpinner.CycleEvent> getOnCycle()
      Gets the value of the property onCycle.
      Property description:
      OnCycle: callback for when the list cycles to the other end in cyclic mode (for example to increase a year when a month ListSpinner skips from December to January)
    • setOnCycle

      public void setOnCycle(javafx.event.EventHandler<ListSpinner.CycleEvent> value)
      Sets the value of the property onCycle.
      Property description:
      OnCycle: callback for when the list cycles to the other end in cyclic mode (for example to increase a year when a month ListSpinner skips from December to January)
    • withOnCycle

      public ListSpinner<T> withOnCycle(javafx.event.EventHandler<ListSpinner.CycleEvent> value)
    • fireCycleEvent

      public void fireCycleEvent(ListSpinner.CycleDirection cycleDirection)
      we're cycling, fire the event
    • first

      public void first()
    • decrement

      public void decrement()
    • increment

      public void increment()
    • last

      public void last()
      Get the last index; if the data provide is endless, this method mail fail!
    • equals

      public static boolean equals(Object o1, Object o2)
      Does a o1.equals(o2) but also checks if o1 or o2 are null.
      Parameters:
      o1 -
      o2 -
      Returns:
      True if the two values are equal, false otherwise.