- All Implemented Interfaces:
Skin<MFXSpinner<T>>
MFXSpinner.
There are two main components:
1) The top container, a BorderPane, which contains the spinner's text field
and the two icons. The usage of a BorderPane simplifies a lot the layout since it's
everything automatically handled. This allows to easily switch the spinner's orientation,
MFXSpinner.orientationProperty(), and handle the icons.
2) A MFXTextField to show the spinner's selected value as text. Here things are a bit
more complicated. The field's text is not simply bound but it's computed by a StringBinding.
This is needed because there are several things to consider since the spinner relies on SpinnerModel
to handle the selected value and also the way to convert the value to text.
It's needed, for example, to keep track of both the MFXSpinner.spinnerModelProperty() and
the SpinnerModel.converterProperty() at the same time.
PseudoClass: ":focus-within", it is activated when
the text field is focused or when one of the icons is focused.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected doublecomputeMaxHeight(double width, double topInset, double rightInset, double bottomInset, double leftInset) protected doublecomputeMaxWidth(double height, double topInset, double rightInset, double bottomInset, double leftInset) protected doublecomputeMinWidth(double height, double topInset, double rightInset, double bottomInset, double leftInset) protected doublecomputePrefWidth(double height, double topInset, double rightInset, double bottomInset, double leftInset) voiddispose()Methods inherited from class javafx.scene.control.SkinBase
computeBaselineOffset, computeMinHeight, computePrefHeight, consumeMouseEvents, executeAccessibleAction, getChildren, getClassCssMetaData, getCssMetaData, getNode, getSkinnable, layoutChildren, layoutInArea, layoutInArea, layoutInArea, positionInArea, positionInArea, pseudoClassStateChanged, queryAccessibleAttribute, registerChangeListener, registerInvalidationListener, registerListChangeListener, snappedBottomInset, snappedLeftInset, snappedRightInset, snappedTopInset, snapPosition, snapPositionX, snapPositionY, snapSize, snapSizeX, snapSizeY, snapSpace, snapSpaceX, snapSpaceY, unregisterChangeListeners, unregisterInvalidationListeners, unregisterListChangeListeners
-
Constructor Details
-
MFXSpinnerSkin
-
-
Method Details
-
computeMinWidth
protected double computeMinWidth(double height, double topInset, double rightInset, double bottomInset, double leftInset) - Overrides:
computeMinWidthin classSkinBase<MFXSpinner<T>>
-
computePrefWidth
protected double computePrefWidth(double height, double topInset, double rightInset, double bottomInset, double leftInset) - Overrides:
computePrefWidthin classSkinBase<MFXSpinner<T>>
-
computeMaxWidth
protected double computeMaxWidth(double height, double topInset, double rightInset, double bottomInset, double leftInset) - Overrides:
computeMaxWidthin classSkinBase<MFXSpinner<T>>
-
computeMaxHeight
protected double computeMaxHeight(double width, double topInset, double rightInset, double bottomInset, double leftInset) - Overrides:
computeMaxHeightin classSkinBase<MFXSpinner<T>>
-
dispose
public void dispose()
-