File: spinbutt.tex

package info (click to toggle)
wxwidgets2.8 2.8.10.1-3
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 239,052 kB
  • ctags: 289,550
  • sloc: cpp: 1,838,857; xml: 396,717; python: 282,506; ansic: 126,171; makefile: 51,406; sh: 14,581; asm: 299; sql: 258; lex: 194; perl: 139; yacc: 128; pascal: 95; php: 39; lisp: 38; tcl: 24; haskell: 20; java: 18; cs: 18; erlang: 17; ruby: 16; ada: 9; ml: 9; csh: 9
file content (155 lines) | stat: -rw-r--r-- 4,703 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
\section{\class{wxSpinButton}}\label{wxspinbutton}

A wxSpinButton has two small up and down (or left and right) arrow buttons. It
is often used next to a text control for increment and decrementing a value.
Portable programs should try to use \helpref{wxSpinCtrl}{wxspinctrl} instead
as wxSpinButton is not implemented for all platforms but wxSpinCtrl is as it
degenerates to a simple \helpref{wxTextCtrl}{wxtextctrl} on such platforms.

{\bf NB:} the range supported by this control (and wxSpinCtrl) depends on the
platform but is at least {\tt -0x8000} to {\tt 0x7fff}. Under GTK and
Win32 with sufficiently new version of {\tt comctrl32.dll} (at least 4.71 is
required, 5.80 is recommended) the full 32 bit range is supported.

\wxheading{Derived from}

\helpref{wxControl}{wxcontrol}\\
\helpref{wxWindow}{wxwindow}\\
\helpref{wxEvtHandler}{wxevthandler}\\
\helpref{wxObject}{wxobject}

\wxheading{See also}

\helpref{wxSpinCtrl}{wxspinctrl} 

\wxheading{Include files}

<wx/spinbutt.h>

\wxheading{Window styles}

\twocolwidtha{5cm}
\begin{twocollist}\itemsep=0pt
\twocolitem{\windowstyle{wxSP\_HORIZONTAL}}{Specifies a horizontal spin button (note that this style is not supported in wxGTK).}
\twocolitem{\windowstyle{wxSP\_VERTICAL}}{Specifies a vertical spin button.}
\twocolitem{\windowstyle{wxSP\_ARROW\_KEYS}}{The user can use arrow keys to change the value.}
\twocolitem{\windowstyle{wxSP\_WRAP}}{The value wraps at the minimum and maximum.}
\end{twocollist}

See also \helpref{window styles overview}{windowstyles}.

\input spinevt.inc

\wxheading{See also}

\helpref{Event handling overview}{eventhandlingoverview}

\latexignore{\rtfignore{\wxheading{Members}}}

\membersection{wxSpinButton::wxSpinButton}\label{wxspinbuttonctor}

\func{}{wxSpinButton}{\void}

Default constructor.

\func{}{wxSpinButton}{\param{wxWindow*}{ parent}, \param{wxWindowID }{id},\rtfsp
\param{const wxPoint\& }{pos = wxDefaultPosition}, \param{const wxSize\& }{size = wxDefaultSize},\rtfsp
\param{long}{ style = wxSP\_HORIZONTAL},\rtfsp
\param{const wxString\& }{name = ``spinButton"}}

Constructor, creating and showing a spin button.

\wxheading{Parameters}

\docparam{parent}{Parent window. Must not be NULL.}

\docparam{id}{Window identifier. A value of -1 indicates a default value.}

\docparam{pos}{Window position. If the position (-1, -1) is specified then a default position is chosen.}

\docparam{size}{Window size. If the default size (-1, -1) is specified then a default size is chosen.}

\docparam{style}{Window style. See \helpref{wxSpinButton}{wxspinbutton}.}

\docparam{name}{Window name.}

\wxheading{See also}

\helpref{wxSpinButton::Create}{wxspinbuttoncreate}

\membersection{wxSpinButton::\destruct{wxSpinButton}}\label{wxspinbuttondtor}

\func{void}{\destruct{wxSpinButton}}{\void}

Destructor, destroys the spin button control.

\membersection{wxSpinButton::Create}\label{wxspinbuttoncreate}

\func{bool}{Create}{\param{wxWindow*}{ parent}, \param{wxWindowID }{id},\rtfsp
\param{const wxPoint\& }{pos = wxDefaultPosition}, \param{const wxSize\& }{size = wxDefaultSize},\rtfsp
\param{long}{ style = wxSP\_HORIZONTAL},\rtfsp
\param{const wxString\& }{name = ``spinButton"}}

Scrollbar creation function called by the spin button constructor.
See \helpref{wxSpinButton::wxSpinButton}{wxspinbuttonctor} for details.

\membersection{wxSpinButton::GetMax}\label{wxspinbuttongetmax}

\constfunc{int}{GetMax}{\void}

Returns the maximum permissible value.

\wxheading{See also}

\helpref{wxSpinButton::SetRange}{wxspinbuttonsetrange}

\membersection{wxSpinButton::GetMin}\label{wxspinbuttongetmin}

\constfunc{int}{GetMin}{\void}

Returns the minimum permissible value.

\wxheading{See also}

\helpref{wxSpinButton::SetRange}{wxspinbuttonsetrange}

\membersection{wxSpinButton::GetValue}\label{wxspinbuttongetvalue}

\constfunc{int}{GetValue}{\void}

Returns the current spin button value.

\wxheading{See also}

\helpref{wxSpinButton::SetValue}{wxspinbuttonsetvalue}

\membersection{wxSpinButton::SetRange}\label{wxspinbuttonsetrange}

\func{void}{SetRange}{\param{int}{ min}, \param{int}{ max}}

Sets the range of the spin button.

\wxheading{Parameters}

\docparam{min}{The minimum value for the spin button.}

\docparam{max}{The maximum value for the spin button.}

\wxheading{See also}

\helpref{wxSpinButton::GetMin}{wxspinbuttongetmin}, \helpref{wxSpinButton::GetMax}{wxspinbuttongetmax}

\membersection{wxSpinButton::SetValue}\label{wxspinbuttonsetvalue}

\func{void}{SetValue}{\param{int}{ value}}

Sets the value of the spin button.

\wxheading{Parameters}

\docparam{value}{The value for the spin button.}

\wxheading{See also}

\helpref{wxSpinButton::GetValue}{wxspinbuttongetvalue}