Module is.codion.swing.common.ui
Interface ToggleMenuItemBuilder<C extends JMenuItem,B extends ToggleMenuItemBuilder<C,B>>
- All Superinterfaces:
ButtonBuilder<Boolean,
,C, B> ComponentBuilder<Boolean,
C, B>
- All Known Subinterfaces:
CheckBoxMenuItemBuilder<B>
,RadioButtonMenuItemBuilder<B>
public interface ToggleMenuItemBuilder<C extends JMenuItem,B extends ToggleMenuItemBuilder<C,B>>
extends ButtonBuilder<Boolean,C,B>
Builds a toggle menu item.
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic enum
Specifies whether a menu is kept open after a toggle menu item has been toggled. -
Field Summary
Modifier and TypeFieldDescriptionstatic final PropertyValue<ToggleMenuItemBuilder.PersistMenu>
Specifies whether a menu persists after a toggle menu item has been toggled Value type:ToggleMenuItemBuilder.PersistMenu
Default value:ToggleMenuItemBuilder.PersistMenu.ALWAYS
Fields inherited from interface is.codion.swing.common.ui.component.builder.ComponentBuilder
COMPONENT_VALUE, TRANSFER_FOCUS_ON_ENTER
-
Method Summary
Modifier and TypeMethodDescriptionpersistMenu
(ToggleMenuItemBuilder.PersistMenu persistMenu) toggleControl
(Control.Builder<ToggleControl, ?> toggleControlBuilder) toggleControl
(ToggleControl toggleControl) Methods inherited from interface is.codion.swing.common.ui.component.button.ButtonBuilder
action, actionListener, borderPainted, buttonGroup, contentAreaFilled, control, control, disabledIcon, disabledSelectedIcon, focusPainted, horizontalAlignment, horizontalTextPosition, icon, iconTextGap, includeText, margin, mnemonic, multiClickThreshold, pressedIcon, rolloverEnabled, rolloverIcon, rolloverSelectedIcon, selected, selectedIcon, text, verticalAlignment, verticalTextPosition
Methods inherited from interface is.codion.swing.common.ui.component.builder.ComponentBuilder
background, border, build, build, buildValue, buildValue, clientProperty, componentListener, componentOrientation, consumer, enabled, enabled, focusable, focusCycleRoot, focusListener, font, foreground, keyEvent, keyListener, label, link, link, listener, maximumHeight, maximumSize, maximumWidth, minimumHeight, minimumSize, minimumWidth, mouseListener, mouseMotionListener, mouseWheelListener, onBuild, onBuildValue, onSetVisible, opaque, popupMenu, popupMenuControl, popupMenuControls, preferredHeight, preferredSize, preferredWidth, propertyChangeListener, propertyChangeListener, scrollPane, toolTipText, transferFocusOnEnter, transferHandler, validator, value, visible
-
Field Details
-
PERSIST_MENU
Specifies whether a menu persists after a toggle menu item has been toggled- Value type:
ToggleMenuItemBuilder.PersistMenu
- Default value:
ToggleMenuItemBuilder.PersistMenu.ALWAYS
- Value type:
-
-
Method Details
-
toggleControl
- Parameters:
toggleControl
- the toggle control to base this toggle menu item on- Returns:
- this builder instance
-
toggleControl
- Parameters:
toggleControlBuilder
- the builder for the toggle control to base this toggle menu on- Returns:
- this builder instance
-
persistMenu
- Parameters:
persistMenu
- specifies when a menu persists after a toggle button click- Returns:
- this builder instance
-