java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.AbstractButton
javax.swing.JMenuItem
javax.swing.JRadioButtonMenuItem
All Implemented Interfaces:
Accessible, MenuElement, SwingConstants, ItemSelectable, HasGetTransferHandler, Serializable, MenuContainer, ImageObserver
JRadioButtonMenuItem is
a menu item that is part of a group of menu items in which only one
item in the group can be selected. The selected item displays its
selected state. Selecting it causes any other selected item to
switch to the unselected state.
To control the selected state of a group of radio button menu items,
use a ButtonGroup object.
Menu items can be configured, and to some degree controlled, by
Actions. Using an
Action with a menu item has many benefits beyond directly
configuring a menu item. Refer to
Swing Components Supporting Action for more
details, and you can find more information in How
to Use Actions, a section in The Java Tutorial.
For further documentation and examples see How to Use Menus, a section in The Java Tutorial.
Warning: Swing is not thread safe. For more information see Swing's Threading Policy.
Warning:
Serialized objects of this class will not be compatible with
future Swing releases. The current serialization support is
appropriate for short term storage or RMI between applications running
the same version of Swing. As of 1.4, support for long term storage
of all JavaBeansTM
has been added to the java.beans package.
Please see java.beans.XMLEncoder .
attribute - : isContainer false
description: A component within a group of menu items which can be selected.Georges - SaabDavid - Karlton| Nested Class Summary: | ||
|---|---|---|
| protected class | JRadioButtonMenuItem.AccessibleJRadioButtonMenuItem | This class implements accessibility support for the
JRadioButtonMenuItem class. It provides an
implementation of the Java Accessibility API appropriate to
JRadioButtonMenuItem user-interface elements.
Warning:
Serialized objects of this class will not be compatible with
future Swing releases. The current serialization support is
appropriate for short term storage or RMI between applications running
the same version of Swing. As of 1.4, support for long term storage
of all JavaBeansTM
has been added to the |
| Fields inherited from java.awt.Container: |
|---|
| ncomponents, component, layoutMgr, containerListener, listeningChildren, listeningBoundsChildren, descendantsCount, INCLUDE_SELF, SEARCH_HEAVYWEIGHTS, modalComp, modalAppContext |
| Constructor: |
|---|
JRadioButtonMenuItem with no set text or icon. |
JRadioButtonMenuItem with an icon.
|
JRadioButtonMenuItem with text.
|
Action supplied.
|
Icon.
|
|
|
|
| Method from javax.swing.JRadioButtonMenuItem Summary: |
|---|
| getAccessibleContext, getUIClassID, paramString, shouldUpdateSelectedStateFromAction |
| Methods from java.lang.Object: |
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method from javax.swing.JRadioButtonMenuItem Detail: |
|---|
|
|
JRadioButtonMenuItem. This method
is intended to be used only for debugging purposes, and the
content and format of the returned string may vary between
implementations. The returned string may be empty but may not
be null. |
|