borland Packages Class Hierarchy dbswing Package
java.lang.Object +----java.awt.Component +----java.awt.Container +----javax.swing.JComponent +----javax.swing.AbstractButton +----javax.swing.JMenuItem +----javax.swing.JRadioButtonMenuItem +----com.borland.dbswing.IntlRadioButtonMenuItem
Variables Constructors Properties Methods Event Listeners
Implements ImageObserver, ItemSelectable, MenuContainer, Serializable, Accessible, MenuElement, SwingConstants
IntlRadioButtonMenuItem
is an extension of JRadioButtonMenuItem
. An IntlRadioButtonMenuItem
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 in the group to switch to the unselected state.
IntlRadioButtonMenuItem
adds the textWithMnemonic
property for internationalization support. setTextWithMnemonic()
accepts a text string containing an ampersand (&) preceding the character to be used as the menu item's mnemonic character. This makes internationalization easier because the text and mnemonic can be translated as a single string. A translator given a list of strings to translate need not match single mnemonic characters in isolation with their corresponding menu names.
IntlMenuItem
, IntlMenu
public IntlRadioButtonMenuItem()Creates an
IntlRadioButtonMenuItem
. Calls the constructor of this
class which takes a String
, Icon
, and boolean
for parameters. Passes null
, null
, and false
to the other constructor.
public IntlRadioButtonMenuItem(String text)Creates an
IntlRadioButtonMenuItem
that contains the specified text. Calls the constructor of this
class which takes a String
, Icon
, and boolean
for parameters. Passes the specified text string, null
, and false
to the other constructor.
text
public IntlRadioButtonMenuItem(String text, boolean b)Creates an
IntlRadioButtonMenuItem
that contains the specified text. Calls the constructor of this
class that takes a String
as a parameter. Calls setSelected()
and passes it the specified boolean
value.
text
b
true
, the menu item is selected; if false
, the menu item is unselected.
public IntlRadioButtonMenuItem(String text, Icon icon)Creates an
IntlRadioButtonMenuItem
that contains the specified text and an icon. Calls the constructor of this
class which takes a String
, Icon
, and boolean
for parameters. Passes the specified text string and icon, and a boolean
value of false
to the other constructor.
text
icon
public IntlRadioButtonMenuItem(String text, Icon icon, boolean selected)Creates an
IntlRadioButtonMenuItem
that contains the specified text and an icon. The radio button menu item is initially selected if the selected
parameter is true
; if selected
is false
, the radio button menu item is not selected. Calls the constructor of its superclass, passing it all three parameters.
text
icon
Icon
that appears on the menu item.
selected
true
, the menu item is selected; if false
, the menu item is unselected.
public IntlRadioButtonMenuItem(Icon icon)Creates an
IntlRadioButtonMenuItem
that contains a specified icon. The radio button menu item is initially selected if the selected
parameter is true
; if selected
is false
, the radio button menu item is not selected. Calls the constructor of this
class which takes a String
, Icon
, and boolean
for parameters. Passes null
, the specified icon, and false
to the other constructor.
icon
Icon
that appears on the menu item.
public IntlRadioButtonMenuItem(Icon icon, boolean selected)Creates an
IntlRadioButtonMenuItem
that contains a specified icon. Calls the constructor of this
class which takes a String
, Icon
, and boolean
for parameters. Passes null
, null
, and false
to the other constructor.
icon
Icon
that appears on the menu item.
selected
true
, the menu item is selected; if false
, the menu item is unselected.
public String getTextWithMnemonic() public void setTextWithMnemonic(String text)
textWithMnemonic
is a convenience property for setting the menu item's text, which interprets an ampersand character (&) within the text as an instruction to make the character following the ampersand the mnemonic character for the menu item. To put an ampersand in the text but not make the character following it a hot key, put a backslash before the ampersand. To make the ampersand the hot key, put two consecutive ampersands in the text.
This property can be used instead of the usual text
property, even if a mnemonic character is not embedded in the text. It is particularly useful for applications that resource strings for internationalization, because the text and mnemonic can be specified in a single string.
Note that the first occurrence of the mnemonic character is always denoted visibly as the mnemonic key, despite the location of the ampersand within the text. Furthermore, only the first occurrence of an ampersand is removed from the text.
If both the text
and textWithMnemonic
properties are set, the most recently set property takes precedence.
textWithMnemonic
is a bound property, and therefore a property change event is fired when its value is modified.
public void addActionListener(java.awt.event.ActionListener ) public void removeActionListener(java.awt.event.ActionListener )
public void addAncestorListener(javax.swing.event.AncestorListener ) public void removeAncestorListener(javax.swing.event.AncestorListener )
public void addChangeListener(javax.swing.event.ChangeListener ) public void removeChangeListener(javax.swing.event.ChangeListener )
public synchronized void addComponentListener(java.awt.event.ComponentListener ) public synchronized void removeComponentListener(java.awt.event.ComponentListener )
public synchronized void addContainerListener(java.awt.event.ContainerListener ) public synchronized void removeContainerListener(java.awt.event.ContainerListener )
public synchronized void addFocusListener(java.awt.event.FocusListener ) public synchronized void removeFocusListener(java.awt.event.FocusListener )
public synchronized void addInputMethodListener(java.awt.event.InputMethodListener ) public synchronized void removeInputMethodListener(java.awt.event.InputMethodListener )
public void addItemListener(java.awt.event.ItemListener ) public void removeItemListener(java.awt.event.ItemListener )
public synchronized void addKeyListener(java.awt.event.KeyListener ) public synchronized void removeKeyListener(java.awt.event.KeyListener )
public void addMenuDragMouseListener(javax.swing.event.MenuDragMouseListener ) public void removeMenuDragMouseListener(javax.swing.event.MenuDragMouseListener )
public void addMenuKeyListener(javax.swing.event.MenuKeyListener ) public void removeMenuKeyListener(javax.swing.event.MenuKeyListener )
public synchronized void addMouseListener(java.awt.event.MouseListener ) public synchronized void removeMouseListener(java.awt.event.MouseListener )
public synchronized void addMouseMotionListener(java.awt.event.MouseMotionListener ) public synchronized void removeMouseMotionListener(java.awt.event.MouseMotionListener )
public synchronized void addPropertyChangeListener(java.beans.PropertyChangeListener ) public synchronized void removePropertyChangeListener(java.beans.PropertyChangeListener )
public synchronized void addVetoableChangeListener(java.beans.VetoableChangeListener ) public synchronized void removeVetoableChangeListener(java.beans.VetoableChangeListener )