java.lang.Object
javafx.scene.control.MenuItem
javafx.scene.control.CustomMenuItem
atlantafx.base.controls.CaptionMenuItem
- All Implemented Interfaces:
javafx.css.Styleable,javafx.event.EventTarget
public class CaptionMenuItem
extends javafx.scene.control.CustomMenuItem
A MenuItem that is intended to contain a caption for a group of menu items
that share a common purpose.
-
Property Summary
PropertiesTypePropertyDescriptionjavafx.beans.property.StringPropertyContains the title of the menu item.Properties inherited from class javafx.scene.control.CustomMenuItem
content, hideOnClickProperties inherited from class javafx.scene.control.MenuItem
accelerator, disable, graphic, id, mnemonicParsing, onAction, onMenuValidation, parentMenu, parentPopup, style, text, visible -
Field Summary
FieldsFields inherited from class javafx.scene.control.MenuItem
MENU_VALIDATION_EVENT -
Constructor Summary
ConstructorsConstructorDescriptionCreates an empty menu item.CaptionMenuItem(@Nullable String text) Creates a CaptionMenuItem with the specified text as the title. -
Method Summary
Modifier and TypeMethodDescriptiongetTitle()Gets the value of thetitleproperty.voidSets the value of thetitleproperty.javafx.beans.property.StringPropertyContains the title of the menu item.Methods inherited from class javafx.scene.control.CustomMenuItem
contentProperty, getContent, hideOnClickProperty, isHideOnClick, setContent, setHideOnClickMethods inherited from class javafx.scene.control.MenuItem
acceleratorProperty, addEventFilter, addEventHandler, buildEventDispatchChain, disableProperty, fire, getAccelerator, getCssMetaData, getGraphic, getId, getOnAction, getOnMenuValidation, getParentMenu, getParentPopup, getProperties, getPseudoClassStates, getStyle, getStyleableNode, getStyleableParent, getStyleClass, getText, getTypeSelector, getUserData, graphicProperty, idProperty, isDisable, isMnemonicParsing, isVisible, mnemonicParsingProperty, onActionProperty, onMenuValidationProperty, parentMenuProperty, parentPopupProperty, removeEventFilter, removeEventHandler, setAccelerator, setDisable, setGraphic, setId, setMnemonicParsing, setOnAction, setOnMenuValidation, setParentMenu, setParentPopup, setStyle, setText, setUserData, setVisible, styleProperty, textProperty, toString, visibleProperty
-
Property Details
-
title
public javafx.beans.property.StringProperty titlePropertyContains the title of the menu item.- See Also:
-
-
Field Details
-
title
protected final javafx.scene.control.Label title
-
-
Constructor Details
-
CaptionMenuItem
public CaptionMenuItem()Creates an empty menu item. -
CaptionMenuItem
Creates a CaptionMenuItem with the specified text as the title.
-
-
Method Details
-
titleProperty
public javafx.beans.property.StringProperty titleProperty()Contains the title of the menu item.- Returns:
- the
titleproperty - See Also:
-
getTitle
Gets the value of thetitleproperty.- Property description:
- Contains the title of the menu item.
- Returns:
- the value of the
titleproperty - See Also:
-
setTitle
Sets the value of thetitleproperty.- Property description:
- Contains the title of the menu item.
- Parameters:
text- the value for thetitleproperty- See Also:
-