RadioButton

RadioButton[x,val]

represents a radio button whose setting x is set to val when the button is clicked.

RadioButton[x,val]

is displayed as when x is val, and as otherwise.

RadioButton[Dynamic[x],val]

takes the setting to be the dynamically updated current value of x, with the value of x being reset if the button is clicked.

Details and Options

Examples

open allclose all

Basic Examples  (1)

Dynamically change the value of x:

Options  (9)

Appearance  (2)

Control the appearance:

Dynamically change the appearance:

AutoAction  (1)

Values update as the cursor is moved over the clickable area:

Background  (2)

Set the background color:

Dynamically change the background color:

BaselinePosition  (1)

Align with surrounding text:

Enabled  (2)

By default RadioButton is enabled:

By setting Enabled->False, the radio button is disabled, but visible in its current state:

ImageMargins  (1)

Increase the clickable area of RadioButton:

Properties & Relations  (2)

RadioButtonBar uses RadioButton with the same variable:

RadioButton is a special case of Setter:

Introduced in 2007
 (6.0)