1 \section{\class{wxRadioButton
}}\label{wxradiobutton
}
3 A radio button item is a button which usually denotes one of several mutually
4 exclusive options. It has a text label next to a (usually) round button.
6 \wxheading{Derived from
}
8 \helpref{wxControl
}{wxcontrol
}\\
9 \helpref{wxWindow
}{wxwindow
}\\
10 \helpref{wxEvtHandler
}{wxevthandler
}\\
11 \helpref{wxObject
}{wxobject
}
13 \wxheading{Include files
}
17 \wxheading{Window styles
}
20 \begin{twocollist
}\itemsep=
0pt
21 \twocolitem{\windowstyle{wxRB
\_GROUP}}{Marks the beginning of a new group of radio buttons.
}
24 See also
\helpref{window styles overview
}{windowstyles
}.
26 \wxheading{Event handling
}
29 \begin{twocollist
}\itemsep=
0pt
30 \twocolitem{{\bf EVT
\_RADIOBUTTON(id, func)
}}{Process a wxEVT
\_COMMAND\_RADIOBUTTON\_SELECTED event,
31 when the radiobutton is clicked.
}
36 \helpref{Event handling overview
}{eventhandlingoverview
},
\helpref{wxRadioBox
}{wxradiobox
},
\rtfsp
37 \helpref{wxCheckBox
}{wxcheckbox
}
39 \latexignore{\rtfignore{\wxheading{Members
}}}
41 \membersection{wxRadioButton::wxRadioButton
}\label{wxradiobuttonconstr
}
43 \func{}{wxRadioButton
}{\void}
47 \func{}{wxRadioButton
}{\param{wxWindow*
}{ parent
},
\param{wxWindowID
}{ id
},
\param{const wxString\&
}{label
},
\rtfsp
48 \param{const wxPoint\&
}{pos = wxDefaultPosition
},
\param{const wxSize\&
}{ size = wxDefaultSize
},
\rtfsp
49 \param{long
}{ style =
0},
\rtfsp
50 \param{const wxValidator\&
}{validator = wxDefaultValidator
},
\rtfsp
51 \param{const wxString\&
}{name = ``radioButton"
}}
53 Constructor, creating and showing a radio button.
55 \wxheading{Parameters
}
57 \docparam{parent
}{Parent window. Must not be NULL.
}
59 \docparam{id
}{Window identifier. A value of -
1 indicates a default value.
}
61 \docparam{label
}{Label for the radio button.
}
63 \docparam{pos
}{Window position. If the position (-
1, -
1) is specified then a default position is chosen.
}
65 \docparam{size
}{Window size. If the default size (-
1, -
1) is specified then a default size is chosen.
}
67 \docparam{style
}{Window style. See
\helpref{wxRadioButton
}{wxradiobutton
}.
}
69 \docparam{validator
}{Window validator.
}
71 \docparam{name
}{Window name.
}
75 \helpref{wxRadioButton::Create
}{wxradiobuttoncreate
},
\helpref{wxValidator
}{wxvalidator
}
77 \membersection{wxRadioButton::
\destruct{wxRadioButton
}}
79 \func{void
}{\destruct{wxRadioButton
}}{\void}
81 Destructor, destroying the radio button item.
83 \membersection{wxRadioButton::Create
}\label{wxradiobuttoncreate
}
85 \func{bool
}{Create
}{\param{wxWindow*
}{ parent
},
\param{wxWindowID
}{ id
},
\param{const wxString\&
}{label
},
\rtfsp
86 \param{const wxPoint\&
}{pos = wxDefaultPosition
},
\param{const wxSize\&
}{ size = wxDefaultSize
},
\rtfsp
87 \param{long
}{ style =
0},
\rtfsp
88 \param{const wxValidator\&
}{validator = wxDefaultValidator
},
\rtfsp
89 \param{const wxString\&
}{name = ``radioButton"
}}
91 Creates the choice for two-step construction. See
\helpref{wxRadioButton::wxRadioButton
}{wxradiobuttonconstr
} for
94 \membersection{wxRadioButton::GetValue
}\label{wxradiobuttongetvalue
}
96 \constfunc{bool
}{GetValue
}{\void}
98 Returns TRUE if the radio button is depressed, FALSE otherwise.
100 \membersection{wxRadioButton::SetValue
}\label{wxradiobuttonsetvalue
}
102 \func{void
}{SetValue
}{\param{const bool
}{ value
}}
104 Sets the radio button to selected or deselected status. This does not cause a
105 wxEVT
\_COMMAND\_RADIOBUTTON\_SELECTED event to get emitted.
107 \wxheading{Parameters
}
109 \docparam{value
}{TRUE to select, FALSE to deselect.
}