Basics

Guides

API Reference

Menu

Basics

Guides

API Reference

class: ComboBoxBase

[18:7] extends: Control

The ComboBoxBase class wraps javafx.scene.control.ComboBoxBase, the abstract base for the pop-up value controls (ComboBox, ColorPicker, DatePicker). It extends Control and provides the shared value, editability, prompt text, armed state, pop-up show/hide behavior, and the action and show/hide event handlers that every one of these controls inherits. This wrapper is not constructed directly. Concrete controls extend it, mirroring the JavaFX inheritance model, and may specialize members such as getValue and setValue for their own value type.

Methods

  • ComboBoxBase ()

    Base constructor. ComboBoxBase is abstract and is never instantiated on its own.

  • setValue (Value)

    Sets the current value of the control. Accepts a primitive, a raw AJO, or null. Subclasses whose value is a wrapped object (for example ColorPicker with a Color) override this method to unwrap the value.

    • @p Value is the value to set.
    • @r this object for chaining
  • getValue ()

    Returns the current value of the control.

    • @r The current value, or null.
  • valueProperty ()

    Returns the ObjectProperty backing the value.

    • @r An AJO wrapping ObjectProperty.
  • setEditable (bool Editable)

    Sets whether the control's text can be edited directly.

    • @p Editable is a bool; true allows editing.
    • @r this object for chaining
  • isEditable ()

    Returns whether the control is editable.

    • @r A bool that is true when editing is allowed.
  • editableProperty ()

    Returns the BooleanProperty backing the editable flag.

    • @r An AJO wrapping javafx.beans.property.BooleanProperty.
  • setPromptText (string Text)

    Sets the prompt text shown when the control has no value.

    • @p Text is a string with the prompt text.
    • @r this object for chaining
  • getPromptText ()

    Returns the prompt text.

    • @r A string with the prompt text, or null when none is set.
  • promptTextProperty ()

    Returns the StringProperty backing the prompt text.

    • @r An AJO wrapping javafx.beans.property.StringProperty.
  • arm ()

    Arms the control, indicating a mouse press is in progress.

    • @r this object for chaining
  • disarm ()

    Disarms the control.

    • @r this object for chaining
  • isArmed ()

    Returns whether the control is currently armed.

    • @r A bool that is true while the control is armed.
  • armedProperty ()

    Returns the BooleanProperty backing the armed state.

    • @r An AJO wrapping javafx.beans.property.BooleanProperty.
  • show ()

    Shows the control's pop-up.

    • @r this object for chaining
  • hide ()

    Hides the control's pop-up.

    • @r this object for chaining
  • isShowing ()

    Returns whether the control's pop-up is showing.

    • @r A bool that is true while the pop-up is visible.
  • showingProperty ()

    Returns the ReadOnlyBooleanProperty backing the showing state.

    • @r An AJO wrapping ReadOnlyBooleanProperty.
  • setOnAction (callback Cb)

    Registers a callback invoked when the control's action fires (for example when the value is committed).

    • @p Cb is a callback invoked with an ActionEvent.
    • @r this object for chaining
  • getOnAction ()

    Returns the onAction handler.

    • @r An AJO wrapping javafx.event.EventHandler, or null.
  • onActionProperty ()

    Returns the ObjectProperty backing the onAction handler.

    • @r An AJO wrapping ObjectProperty.
  • setOnShowing (callback Cb)

    Registers a callback invoked just before the pop-up is shown.

    • @p Cb is a callback invoked with an Event.
    • @r this object for chaining
  • getOnShowing ()

    Returns the onShowing handler.

    • @r An AJO wrapping javafx.event.EventHandler, or null.
  • onShowingProperty ()

    Returns the ObjectProperty backing the onShowing handler.

    • @r An AJO wrapping ObjectProperty.
  • setOnShown (callback Cb)

    Registers a callback invoked just after the pop-up is shown.

    • @p Cb is a callback invoked with an Event.
    • @r this object for chaining
  • getOnShown ()

    Returns the onShown handler.

    • @r An AJO wrapping javafx.event.EventHandler, or null.
  • onShownProperty ()

    Returns the ObjectProperty backing the onShown handler.

    • @r An AJO wrapping ObjectProperty.
  • setOnHiding (callback Cb)

    Registers a callback invoked just before the pop-up is hidden.

    • @p Cb is a callback invoked with an Event.
    • @r this object for chaining
  • getOnHiding ()

    Returns the onHiding handler.

    • @r An AJO wrapping javafx.event.EventHandler, or null.
  • onHidingProperty ()

    Returns the ObjectProperty backing the onHiding handler.

    • @r An AJO wrapping ObjectProperty.
  • setOnHidden (callback Cb)

    Registers a callback invoked just after the pop-up is hidden.

    • @p Cb is a callback invoked with an Event.
    • @r this object for chaining
  • getOnHidden ()

    Returns the onHidden handler.

    • @r An AJO wrapping javafx.event.EventHandler, or null.
  • onHiddenProperty ()

    Returns the ObjectProperty backing the onHidden handler.

    • @r An AJO wrapping ObjectProperty.