Radio button

From Wikipedia, the free encyclopedia

Jump to: navigation, search
Radio buttons, the choice 'Cat' is selected.

A radio button or option button is a type of graphical user interface element that allows the user to choose only one of a predefined set of options. They were named after the physical buttons used on older car radios to select preset stations - when one of the buttons was pressed, other buttons would pop out, leaving the pressed button the only button in the "pushed in" position. Although sometimes called "radial" buttons because of their circular shape, this name is incorrect. The buttons were named for their behavior, not their shape. The name arose in the early 1980s in reference to mechanical car radio buttons seen in older car radios of the time.

Radio buttons are arranged in groups of two or more and displayed on screen as, for example, a list of circular holes that can contain white space (for unselected) or a dot (for selected). Adjacent to each radio button is normally shown a caption describing the choice that this radio button represents. When the user selects a radio button, any previously selected radio button in the same group becomes deselected. Selecting a radio button is done by clicking the mouse on the button, or the caption, or by using a keyboard shortcut.

It is possible that initially none of the radio buttons in a group is selected. This state cannot be restored by interacting with the radio button widget (but it may be possible through other user interface elements). The Apple Human Interface Guidelines specify that one item of a radio button group must always be selected.

When used in an HTML form, if no button in a group is checked, then no name-value pair is passed when the form is submitted. For example, for a radio button group named Gender with the options Male and Female, the variable Gender would not be passed, even with a blank value.

[edit] See also

[edit] External links

Personal tools