- java.lang.Object
-
- javafx.scene.control.MenuItem
-
- javafx.scene.control.CustomMenuItem
-
- javafx.scene.control.SeparatorMenuItem
-
- All Implemented Interfaces:
-
Styleable
,EventTarget
public class SeparatorMenuItem extends CustomMenuItem
A
MenuItem
,如名称所示,允许在其中嵌入一个水平分隔符,通过将Separator
分配给content
属性CustomMenuItem
来提供CustomMenuItem
这是为方便起见提供的,可以通过分隔符分隔menuitems
。 为了这个目的而不是创建一个CustomMenuItem
,用户可以使用这个类,如下所示。SeparatorMenuItem separatorMenuItem = new SeparatorMenuItem();
- 从以下版本开始:
- JavaFX 2.0
- 另请参见:
-
CustomMenuItem
,MenuItem
,Menu
-
-
Property Summary
-
Properties inherited from class javafx.scene.control.CustomMenuItem
content, hideOnClick
-
Properties inherited from class javafx.scene.control.MenuItem
accelerator, disable, graphic, id, mnemonicParsing, onAction, onMenuValidation, parentMenu, parentPopup, style, text, visible
-
-
Field Summary
-
Fields inherited from class javafx.scene.control.MenuItem
MENU_VALIDATION_EVENT
-
-
构造方法摘要
构造方法 Constructor 描述 SeparatorMenuItem()
创建一个默认的SeparatorMenuItem实例。
-
方法摘要
-
Methods inherited from class javafx.scene.control.CustomMenuItem
contentProperty, getContent, hideOnClickProperty, isHideOnClick, setContent, setHideOnClick
-
Methods inherited from class javafx.scene.control.MenuItem
acceleratorProperty, 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, removeEventHandler, setAccelerator, setDisable, setGraphic, setId, setMnemonicParsing, setOnAction, setOnMenuValidation, setParentMenu, setParentPopup, setStyle, setText, setUserData, setVisible, styleProperty, textProperty, toString, visibleProperty
-
-