]>
Commit | Line | Data |
---|---|---|
a660d684 KB |
1 | \section{\class{wxRadioButton}}\label{wxradiobutton} |
2 | ||
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. | |
5 | ||
6 | \wxheading{Derived from} | |
7 | ||
8 | \helpref{wxControl}{wxcontrol}\\ | |
9 | \helpref{wxWindow}{wxwindow}\\ | |
10 | \helpref{wxEvtHandler}{wxevthandler}\\ | |
11 | \helpref{wxObject}{wxobject} | |
12 | ||
13 | \wxheading{Window styles} | |
14 | ||
15 | There are no specific styles for this class. | |
16 | ||
17 | See also \helpref{window styles overview}{windowstyles}. | |
18 | ||
5de76427 JS |
19 | \wxheading{Event handling} |
20 | ||
21 | \twocolwidtha{7cm} | |
22 | \begin{twocollist}\itemsep=0pt | |
23 | \twocolitem{{\bf EVT\_RADIOBUTTON(id, func)}}{Process a wxEVT\_COMMAND\_RADIOBUTTON\_SELECTED event, | |
24 | when the radiobutton is clicked.} | |
25 | \end{twocollist} | |
26 | ||
a660d684 KB |
27 | \wxheading{See also} |
28 | ||
29 | \helpref{Event handling overview}{eventhandlingoverview}, \helpref{wxRadioBox}{wxradiobox},\rtfsp | |
30 | \helpref{wxCheckBox}{wxcheckbox} | |
31 | ||
32 | \latexignore{\rtfignore{\wxheading{Members}}} | |
33 | ||
34 | \membersection{wxRadioButton::wxRadioButton}\label{wxradiobuttonconstr} | |
35 | ||
36 | \func{}{wxRadioButton}{\void} | |
37 | ||
38 | Default constructor. | |
39 | ||
eaaa6a06 | 40 | \func{}{wxRadioButton}{\param{wxWindow*}{ parent}, \param{wxWindowID}{ id}, \param{const wxString\& }{label},\rtfsp |
a660d684 | 41 | \param{const wxPoint\& }{pos = wxDefaultPosition}, \param{const wxSize\&}{ size = wxDefaultSize},\rtfsp |
eaaa6a06 | 42 | \param{long}{ style = 0},\rtfsp |
a660d684 KB |
43 | \param{const wxValidator\& }{validator = wxDefaultValidator},\rtfsp |
44 | \param{const wxString\& }{name = ``radioButton"}} | |
45 | ||
46 | Constructor, creating and showing a radio button. | |
47 | ||
48 | \wxheading{Parameters} | |
49 | ||
50 | \docparam{parent}{Parent window. Must not be NULL.} | |
51 | ||
52 | \docparam{id}{Window identifier. A value of -1 indicates a default value.} | |
53 | ||
54 | \docparam{label}{Label for the radio button.} | |
55 | ||
56 | \docparam{pos}{Window position. If the position (-1, -1) is specified then a default position is chosen.} | |
57 | ||
58 | \docparam{size}{Window size. If the default size (-1, -1) is specified then a default size is chosen.} | |
59 | ||
60 | \docparam{style}{Window style. See \helpref{wxRadioButton}{wxradiobutton}.} | |
61 | ||
62 | \docparam{validator}{Window validator.} | |
63 | ||
64 | \docparam{name}{Window name.} | |
65 | ||
66 | \wxheading{See also} | |
67 | ||
68 | \helpref{wxRadioButton::Create}{wxradiobuttoncreate}, \helpref{wxValidator}{wxvalidator} | |
69 | ||
70 | \membersection{wxRadioButton::\destruct{wxRadioButton}} | |
71 | ||
72 | \func{void}{\destruct{wxRadioButton}}{\void} | |
73 | ||
74 | Destructor, destroying the radio button item. | |
75 | ||
76 | \membersection{wxRadioButton::Create}\label{wxradiobuttoncreate} | |
77 | ||
eaaa6a06 | 78 | \func{bool}{Create}{\param{wxWindow*}{ parent}, \param{wxWindowID}{ id}, \param{const wxString\& }{label},\rtfsp |
a660d684 | 79 | \param{const wxPoint\& }{pos = wxDefaultPosition}, \param{const wxSize\&}{ size = wxDefaultSize},\rtfsp |
eaaa6a06 | 80 | \param{long}{ style = 0},\rtfsp |
a660d684 KB |
81 | \param{const wxValidator\& }{validator = wxDefaultValidator},\rtfsp |
82 | \param{const wxString\& }{name = ``radioButton"}} | |
83 | ||
84 | Creates the choice for two-step construction. See \helpref{wxRadioButton::wxRadioButton}{wxradiobuttonconstr} for | |
85 | further details. | |
86 | ||
87 | \membersection{wxRadioButton::GetValue}\label{wxradiobuttongetvalue} | |
88 | ||
89 | \constfunc{bool}{GetValue}{\void} | |
90 | ||
91 | Returns TRUE if the radio button is depressed, FALSE otherwise. | |
92 | ||
93 | \membersection{wxRadioButton::SetValue}\label{wxradiobuttonsetvalue} | |
94 | ||
95 | \func{void}{SetValue}{\param{const bool}{ value}} | |
96 | ||
97 | Sets the radio button to selected or deselected status. | |
98 | ||
99 | \wxheading{Parameters} | |
100 | ||
101 | \docparam{value}{TRUE to select, FALSE to deselect.} | |
102 | ||
103 |