java.lang.Object
javafx.scene.Node
javafx.scene.Parent
javafx.scene.layout.Region
javafx.scene.control.Control
javafx.scene.control.TextInputControl
javafx.scene.control.TextField
io.github.palexdev.materialfx.controls.MFXTextField
io.github.palexdev.materialfx.controls.MFXComboBox<T>
- All Implemented Interfaces:
MFXCombo<T>,MFXMenuControl,Validated,Styleable,EventTarget,Skinnable
- Direct Known Subclasses:
MFXFilterComboBox
A new, completely remade from scratch
ComboBox for JavaFX.
A combo box is basically a text field which shows a menu of items and allows to select them and set the text accordingly.
That's why my implementation extends MFXTextField and implements MFXCombo.
The major features of this new combo are:
- Floating text (inherited from MFXTextField)
- Allows to fully control the popup (offset, alignment)
- Automatically handles selection when the item's list is modified
- Allows to set the combo as editable or not, and in case of changed text to commit the change (pressing enter by default) and specify how to treat the typed text, or cancel the change (pressing Ctrl+Shift+Z by default).
- Also adds a new PseudoClass that activates when the popup opens
-
Property Summary
PropertiesTypePropertyDescriptionSpecifies the animation of the trailing icon used to open the popup.ObjectProperty<Function<T,io.github.palexdev.virtualizedfx.cell.Cell<T>>> Specifies the function used to create the items cells in the popup.Specifies the converter used to convert an object of type T to a String.Specifies the combo box's items list.Specifies the action to perform onMFXCombo.cancel(String).Specifies the action to perform onMFXCombo.commit(String).Specifies the action when the popup is hidden.Specifies the action when the popup is hiding.Specifies the action when the popup is showing.Specifies the action when the popup is shown.Specifies the popup's alignment.Specifies the popup's x offset.Specifies the popup's y offset.Specifies whether the combo box list should scroll to the current selected value on open.Delegate forSingleSelectionModel.selectedIndexProperty().Delegate forSingleSelectionModel.selectedItemProperty().Specifies whether the popup is showing.Specifies the combo box's value, which does not necessarily coincides with the currently selected item.Properties inherited from class io.github.palexdev.materialfx.controls.MFXTextField
allowEdit, animated, borderGap, caretVisible, delegateAnchor, delegateCaretPosition, delegateFocused, delegateRedoable, delegateSelectedText, delegateSelection, delegateTextFormatter, delegateUndoable, floating, floatingTextGap, floatingText, floatMode, graphicTextGap, leadingIcon, measureUnitGap, measureUnit, scaleOnAbove, selectable, textFill, textLimit, trailingIconProperties inherited from class javafx.scene.control.TextField
alignment, onAction, prefColumnCountProperties inherited from class javafx.scene.control.TextInputControl
anchor, caretPosition, editable, font, length, promptText, redoable, selectedText, selection, textFormatter, text, undoableProperties inherited from class javafx.scene.control.Control
contextMenu, skin, tooltipProperties inherited from class javafx.scene.layout.Region
background, border, cacheShape, centerShape, height, insets, maxHeight, maxWidth, minHeight, minWidth, opaqueInsets, padding, prefHeight, prefWidth, scaleShape, shape, snapToPixel, widthProperties inherited from class javafx.scene.Parent
needsLayoutProperties 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, visibleProperties inherited from interface io.github.palexdev.materialfx.controls.base.MFXCombo
editable, onAction, promptText -
Nested Class Summary
Nested classes/interfaces inherited from class javafx.scene.control.TextInputControl
TextInputControl.Content -
Field Summary
FieldsFields inherited from class io.github.palexdev.materialfx.controls.MFXTextField
boundField, contextMenu, DEFAULT_TEXT_COLOR, floating, validatorFields inherited from class javafx.scene.control.TextField
DEFAULT_PREF_COLUMN_COUNTFields inherited from class javafx.scene.layout.Region
USE_COMPUTED_SIZE, USE_PREF_SIZEFields inherited from class javafx.scene.Node
BASELINE_OFFSET_SAME_AS_HEIGHTFields inherited from interface io.github.palexdev.materialfx.validation.Validated
INVALID_PSEUDO_CLASS -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionSpecifies the animation of the trailing icon used to open the popup.voidIf the combo box is editable and the text has been changed, this method is responsible for deciding what to do with the new text on cancel.ObjectProperty<Function<T,io.github.palexdev.virtualizedfx.cell.Cell<T>>> Specifies the function used to create the items cells in the popup.voidDelegate forSingleSelectionModel.clearSelection().voidIf the combo box is editable and the text has been changed, this method is responsible for deciding what to do with the new text on confirm.Specifies the converter used to convert an object of type T to a String.protected Skin<?>voidGets the value of the property animationProvider.Gets the value of the property cellFactory.static List<CssMetaData<? extends Styleable,?>> List<CssMetaData<? extends Styleable,?>> Gets the value of the property converter.getItems()Gets the value of the property items.Gets the value of the property onCancel.Gets the value of the property onCommit.Gets the value of the property onHidden.Gets the value of the property onHiding.Gets the value of the property onShowing.Gets the value of the property onShown.Gets the value of the property popupAlignment.doubleGets the value of the property popupOffsetX.doubleGets the value of the property popupOffsetY.intDelegate forSingleSelectionModel.getSelectedIndex().Delegate forSingleSelectionModel.getSelectedItem().getValue()Gets the value of the property value.voidhide()Hides the popup.booleanGets the value of the property scrollOnOpen.booleanGets the value of the property showing.protected voiditemsChanged(ListChangeListener.Change<? extends T> change) Responsible for updating the selection when the items list changes.Specifies the combo box's items list.Specifies the action to perform onMFXCombo.cancel(String).Specifies the action to perform onMFXCombo.commit(String).Specifies the action when the popup is hidden.Specifies the action when the popup is hiding.Specifies the action when the popup is showing.Specifies the action when the popup is shown.Specifies the popup's alignment.Specifies the popup's x offset.Specifies the popup's y offset.Specifies whether the combo box list should scroll to the current selected value on open.Delegate forSingleSelectionModel.selectedIndexProperty().Delegate forSingleSelectionModel.selectedItemProperty().voidDelegate forComboBoxSelectionModel.selectFirst().voidselectIndex(int index) Delegate forSingleSelectionModel.selectIndex(int).voidselectItem(T item) Delegate forSingleSelectionModel.selectItem(Object).voidDelegate forComboBoxSelectionModel.selectLast().voidDelegate forComboBoxSelectionModel.selectNext().voidDelegate forComboBoxSelectionModel.selectPrevious().voidsetAnimationProvider(BiFunction<Node, Boolean, Animation> animationProvider) Sets the value of the property animationProvider.voidsetCellFactory(Function<T, io.github.palexdev.virtualizedfx.cell.Cell<T>> cellFactory) Sets the value of the property cellFactory.voidsetConverter(StringConverter<T> converter) Sets the value of the property converter.voidsetItems(ObservableList<T> items) Sets the value of the property items.voidsetOnCancel(Consumer<String> onCancel) Sets the value of the property onCancel.voidsetOnCommit(Consumer<String> onCommit) Sets the value of the property onCommit.voidsetOnHidden(EventHandler<Event> onHidden) Sets the value of the property onHidden.voidsetOnHiding(EventHandler<Event> onHiding) Sets the value of the property onHiding.voidsetOnShowing(EventHandler<Event> onShowing) Sets the value of the property onShowing.voidsetOnShown(EventHandler<Event> onShown) Sets the value of the property onShown.voidsetPopupAlignment(Alignment popupAlignment) Sets the value of the property popupAlignment.voidsetPopupOffsetX(double popupOffsetX) Sets the value of the property popupOffsetX.voidsetPopupOffsetY(double popupOffsetY) Sets the value of the property popupOffsetY.voidsetScrollOnOpen(boolean scrollOnOpen) Sets the value of the property scrollOnOpen.voidSets the value of the property value.voidshow()Shows the popup.Specifies whether the popup is showing.Specifies the combo box's value, which does not necessarily coincides with the currently selected item.Methods inherited from class io.github.palexdev.materialfx.controls.MFXTextField
allowEditProperty, animatedProperty, asLabel, asLabel, asLabel, asLabel, backward, borderGapProperty, caretVisibleProperty, clear, copy, cut, delegateAnchorProperty, delegateCaretPositionProperty, delegateFocusedProperty, delegateGetAnchor, delegateGetCaretPosition, delegateGetSelectedText, delegateGetSelection, delegateGetTextFormatter, delegateIsFocused, delegateIsRedoable, delegateIsUndoable, delegateRedoableProperty, delegateSelectedTextProperty, delegateSelectionProperty, delegateSetTextFormatter, delegateTextFormatterProperty, delegateUndoableProperty, deselect, end, endOfNextWord, extendSelection, floatingProperty, floatingTextGapProperty, floatingTextProperty, floatModeProperty, forward, getBorderGap, getCaretVisible, getFloatingText, getFloatingTextGap, getFloatMode, getGraphicTextGap, getLeadingIcon, getMeasureUnit, getMeasureUnitGap, getMFXContextMenu, getTextFill, getTextLimit, getTrailingIcon, graphicTextGapProperty, home, isAllowEdit, isAnimated, isFloating, isSelectable, leadingIconProperty, measureUnitGapProperty, measureUnitProperty, nextWord, paste, positionCaret, previousWord, replaceSelection, scaleOnAbove, scaleOnAboveProperty, selectableProperty, selectAll, selectBackward, selectEnd, selectEndOfNextWord, selectForward, selectHome, selectNextWord, selectPositionCaret, selectPreviousWord, selectRange, setAllowEdit, setAnimated, setBorderGap, setCaretVisible, setFloatingText, setFloatingTextGap, setFloatMode, setGraphicTextGap, setLeadingIcon, setMeasureUnit, setMeasureUnitGap, setScaleOnAbove, setSelectable, setTextFill, setTextLimit, setTrailingIcon, textFillProperty, textLimitProperty, trailingIconPropertyMethods inherited from class javafx.scene.control.TextField
alignmentProperty, getAlignment, getCharacters, getOnAction, getPrefColumnCount, onActionProperty, prefColumnCountProperty, setAlignment, setOnAction, setPrefColumnCountMethods inherited from class javafx.scene.control.TextInputControl
anchorProperty, appendText, cancelEdit, caretPositionProperty, commitValue, deleteNextChar, deletePreviousChar, deleteText, deleteText, editableProperty, executeAccessibleAction, fontProperty, getAnchor, getCaretPosition, getContent, getFont, getLength, getPromptText, getSelectedText, getSelection, getText, getText, getTextFormatter, insertText, isEditable, isRedoable, isUndoable, lengthProperty, promptTextProperty, queryAccessibleAttribute, redo, redoableProperty, replaceText, replaceText, selectedTextProperty, selectionProperty, setEditable, setFont, setPromptText, setText, setTextFormatter, textFormatterProperty, textProperty, undo, undoablePropertyMethods inherited from class javafx.scene.control.Control
computeMaxHeight, computeMaxWidth, computeMinHeight, computeMinWidth, computePrefHeight, computePrefWidth, contextMenuProperty, getBaselineOffset, getContextMenu, getCssMetaData, getInitialFocusTraversable, getSkin, getTooltip, isResizable, layoutChildren, setContextMenu, setSkin, setTooltip, skinProperty, tooltipPropertyMethods 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, widthPropertyMethods inherited from class javafx.scene.Parent
getChildren, getChildrenUnmodifiable, getManagedChildren, getStylesheets, isNeedsLayout, layout, lookup, needsLayoutProperty, requestLayout, requestParentLayout, setNeedsLayout, updateBoundsMethods 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, visiblePropertyMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface io.github.palexdev.materialfx.controls.base.MFXCombo
editableProperty, getOnAction, getPromptText, isEditable, onActionProperty, promptTextProperty, setEditable, setOnAction, setPromptTextMethods inherited from interface io.github.palexdev.materialfx.controls.base.MFXMenuControl
isContextMenuDisabled, setContextMenuDisabledMethods inherited from interface javafx.css.Styleable
getStyleableNodeMethods inherited from interface io.github.palexdev.materialfx.validation.Validated
isValid, updateInvalid, validate
-
Property Details
-
selectedIndex
Delegate forSingleSelectionModel.selectedIndexProperty().- See Also:
-
selectedItem
Delegate forSingleSelectionModel.selectedItemProperty().- See Also:
-
scrollOnOpen
Specifies whether the combo box list should scroll to the current selected value on open.- See Also:
-
showing
Specifies whether the popup is showing.- See Also:
-
popupAlignment
Specifies the popup's alignment. -
popupOffsetX
Specifies the popup's x offset.- See Also:
-
popupOffsetY
Specifies the popup's y offset.- See Also:
-
animationProvider
Specifies the animation of the trailing icon used to open the popup. -
value
- Specified by:
valuePropertyin interfaceMFXCombo<T>- See Also:
-
converter
- Specified by:
converterPropertyin interfaceMFXCombo<T>- See Also:
-
onCommit
- Specified by:
onCommitPropertyin interfaceMFXCombo<T>- See Also:
-
onCancel
- Specified by:
onCancelPropertyin interfaceMFXCombo<T>- See Also:
-
items
- Specified by:
itemsPropertyin interfaceMFXCombo<T>- See Also:
-
cellFactory
public ObjectProperty<Function<T,io.github.palexdev.virtualizedfx.cell.Cell<T>>> cellFactoryProperty- Specified by:
cellFactoryPropertyin interfaceMFXCombo<T>- See Also:
-
onShowing
- Specified by:
onShowingPropertyin interfaceMFXCombo<T>- See Also:
-
onShown
- Specified by:
onShownPropertyin interfaceMFXCombo<T>- See Also:
-
onHiding
- Specified by:
onHidingPropertyin interfaceMFXCombo<T>- See Also:
-
onHidden
- Specified by:
onHiddenPropertyin interfaceMFXCombo<T>- See Also:
-
-
Field Details
-
POPUP_OPEN_PSEUDO_CLASS
-
ON_SHOWING
-
ON_SHOWN
-
ON_HIDING
-
ON_HIDDEN
-
-
Constructor Details
-
MFXComboBox
public MFXComboBox() -
MFXComboBox
-
-
Method Details
-
defaultContextMenu
public void defaultContextMenu()- Overrides:
defaultContextMenuin classMFXTextField
-
show
public void show()Description copied from interface:MFXComboShows the popup. -
hide
public void hide()Description copied from interface:MFXComboHides the popup. -
commit
If the combo box is editable and the text has been changed, this method is responsible for deciding what to do with the new text on confirm. By default this implementation calls the specifiedonCommitProperty()consumer to perform an action on commit. So, instead of overriding the method you can easily modify its behavior by changing the consumer. -
cancel
If the combo box is editable and the text has been changed, this method is responsible for deciding what to do with the new text on cancel. By default this implementation calls the specifiedonCancelProperty()consumer to perform an action on cancel. So, instead of overriding the method you can easily modify its behavior by changing the consumer. -
itemsChanged
Responsible for updating the selection when the items list changes. -
createDefaultSkin
- Overrides:
createDefaultSkinin classMFXTextField
-
getControlCssMetaData
- Overrides:
getControlCssMetaDatain classMFXTextField
-
getUserAgentStylesheet
- Overrides:
getUserAgentStylesheetin classMFXTextField
-
selectFirst
public void selectFirst()Delegate forComboBoxSelectionModel.selectFirst(). -
selectNext
public void selectNext()Delegate forComboBoxSelectionModel.selectNext(). -
selectPrevious
public void selectPrevious()Delegate forComboBoxSelectionModel.selectPrevious(). -
selectLast
public void selectLast()Delegate forComboBoxSelectionModel.selectLast(). -
clearSelection
public void clearSelection()Delegate forSingleSelectionModel.clearSelection(). -
selectIndex
public void selectIndex(int index) Delegate forSingleSelectionModel.selectIndex(int). -
selectItem
Delegate forSingleSelectionModel.selectItem(Object). -
getSelectedIndex
public int getSelectedIndex()Delegate forSingleSelectionModel.getSelectedIndex(). -
selectedIndexProperty
Delegate forSingleSelectionModel.selectedIndexProperty().- See Also:
-
getSelectedItem
Delegate forSingleSelectionModel.getSelectedItem(). -
selectedItemProperty
Delegate forSingleSelectionModel.selectedItemProperty().- See Also:
-
getValidator
- Specified by:
getValidatorin interfaceValidated- Overrides:
getValidatorin classMFXTextField- Returns:
- the
MFXValidatorinstance of this control
-
isScrollOnOpen
public boolean isScrollOnOpen()Gets the value of the property scrollOnOpen.- Property description:
- Specifies whether the combo box list should scroll to the current selected value on open.
-
scrollOnOpenProperty
Specifies whether the combo box list should scroll to the current selected value on open.- See Also:
-
setScrollOnOpen
public void setScrollOnOpen(boolean scrollOnOpen) Sets the value of the property scrollOnOpen.- Property description:
- Specifies whether the combo box list should scroll to the current selected value on open.
-
getClassCssMetaData
-
isShowing
public boolean isShowing()Gets the value of the property showing.- Property description:
- Specifies whether the popup is showing.
-
showingProperty
Specifies whether the popup is showing.- See Also:
-
getPopupAlignment
Gets the value of the property popupAlignment.- Property description:
- Specifies the popup's alignment.
-
popupAlignmentProperty
Specifies the popup's alignment. -
setPopupAlignment
Sets the value of the property popupAlignment.- Property description:
- Specifies the popup's alignment.
-
getPopupOffsetX
public double getPopupOffsetX()Gets the value of the property popupOffsetX.- Property description:
- Specifies the popup's x offset.
-
popupOffsetXProperty
Specifies the popup's x offset.- See Also:
-
setPopupOffsetX
public void setPopupOffsetX(double popupOffsetX) Sets the value of the property popupOffsetX.- Property description:
- Specifies the popup's x offset.
-
getPopupOffsetY
public double getPopupOffsetY()Gets the value of the property popupOffsetY.- Property description:
- Specifies the popup's y offset.
-
popupOffsetYProperty
Specifies the popup's y offset.- See Also:
-
setPopupOffsetY
public void setPopupOffsetY(double popupOffsetY) Sets the value of the property popupOffsetY.- Property description:
- Specifies the popup's y offset.
-
getAnimationProvider
Gets the value of the property animationProvider.- Property description:
- Specifies the animation of the trailing icon used to open the popup.
-
animationProviderProperty
Specifies the animation of the trailing icon used to open the popup. -
setAnimationProvider
Sets the value of the property animationProvider.- Property description:
- Specifies the animation of the trailing icon used to open the popup.
-
getValue
Gets the value of the property value. -
valueProperty
Description copied from interface:MFXComboSpecifies the combo box's value, which does not necessarily coincides with the currently selected item.- Specified by:
valuePropertyin interfaceMFXCombo<T>- See Also:
-
setValue
Sets the value of the property value. -
getConverter
Gets the value of the property converter.- Specified by:
getConverterin interfaceMFXCombo<T>- Property description:
-
converterProperty
Description copied from interface:MFXComboSpecifies the converter used to convert an object of type T to a String. It is used, for example, to set the combo box text when an item is selected.- Specified by:
converterPropertyin interfaceMFXCombo<T>- See Also:
-
setConverter
Sets the value of the property converter.- Specified by:
setConverterin interfaceMFXCombo<T>- Property description:
-
getOnCommit
Gets the value of the property onCommit.- Specified by:
getOnCommitin interfaceMFXCombo<T>- Property description:
-
onCommitProperty
Description copied from interface:MFXComboSpecifies the action to perform onMFXCombo.commit(String).- Specified by:
onCommitPropertyin interfaceMFXCombo<T>- See Also:
-
setOnCommit
Sets the value of the property onCommit.- Specified by:
setOnCommitin interfaceMFXCombo<T>- Property description:
-
getOnCancel
Gets the value of the property onCancel.- Specified by:
getOnCancelin interfaceMFXCombo<T>- Property description:
-
onCancelProperty
Description copied from interface:MFXComboSpecifies the action to perform onMFXCombo.cancel(String).- Specified by:
onCancelPropertyin interfaceMFXCombo<T>- See Also:
-
setOnCancel
Sets the value of the property onCancel.- Specified by:
setOnCancelin interfaceMFXCombo<T>- Property description:
-
getItems
Gets the value of the property items. -
itemsProperty
Description copied from interface:MFXComboSpecifies the combo box's items list.- Specified by:
itemsPropertyin interfaceMFXCombo<T>- See Also:
-
setItems
Sets the value of the property items. -
getCellFactory
Gets the value of the property cellFactory.- Specified by:
getCellFactoryin interfaceMFXCombo<T>- Property description:
-
cellFactoryProperty
public ObjectProperty<Function<T,io.github.palexdev.virtualizedfx.cell.Cell<T>>> cellFactoryProperty()Description copied from interface:MFXComboSpecifies the function used to create the items cells in the popup.- Specified by:
cellFactoryPropertyin interfaceMFXCombo<T>- See Also:
-
setCellFactory
Sets the value of the property cellFactory.- Specified by:
setCellFactoryin interfaceMFXCombo<T>- Property description:
-
getSelectionModel
- Specified by:
getSelectionModelin interfaceMFXCombo<T>- Returns:
- the combo box' selection model
-
getOnShowing
Gets the value of the property onShowing.- Specified by:
getOnShowingin interfaceMFXCombo<T>- Property description:
-
onShowingProperty
Description copied from interface:MFXComboSpecifies the action when the popup is showing.- Specified by:
onShowingPropertyin interfaceMFXCombo<T>- See Also:
-
setOnShowing
Sets the value of the property onShowing.- Specified by:
setOnShowingin interfaceMFXCombo<T>- Property description:
-
getOnShown
Gets the value of the property onShown.- Specified by:
getOnShownin interfaceMFXCombo<T>- Property description:
-
onShownProperty
Description copied from interface:MFXComboSpecifies the action when the popup is shown.- Specified by:
onShownPropertyin interfaceMFXCombo<T>- See Also:
-
setOnShown
Sets the value of the property onShown.- Specified by:
setOnShownin interfaceMFXCombo<T>- Property description:
-
getOnHiding
Gets the value of the property onHiding.- Specified by:
getOnHidingin interfaceMFXCombo<T>- Property description:
-
onHidingProperty
Description copied from interface:MFXComboSpecifies the action when the popup is hiding.- Specified by:
onHidingPropertyin interfaceMFXCombo<T>- See Also:
-
setOnHiding
Sets the value of the property onHiding.- Specified by:
setOnHidingin interfaceMFXCombo<T>- Property description:
-
getOnHidden
Gets the value of the property onHidden.- Specified by:
getOnHiddenin interfaceMFXCombo<T>- Property description:
-
onHiddenProperty
Description copied from interface:MFXComboSpecifies the action when the popup is hidden.- Specified by:
onHiddenPropertyin interfaceMFXCombo<T>- See Also:
-
setOnHidden
Sets the value of the property onHidden.- Specified by:
setOnHiddenin interfaceMFXCombo<T>- Property description:
-