]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/time.tex
Added size event for status bar
[wxWidgets.git] / docs / latex / wx / time.tex
CommitLineData
a660d684
KB
1\section{\class{wxTime}}\label{wxtime}
2
ce3ed50d 3Representation of time and date.
a660d684
KB
4
5\wxheading{Derived from}
6
7\helpref{wxObject}{wxobject}
8
ce3ed50d
JS
9\wxheading{Data structures}
10
11{\small \begin{verbatim}
12typedef unsigned short hourTy;
13\end{verbatim}}
14
15{\small \begin{verbatim}
16typedef unsigned short minuteTy;
17\end{verbatim}}
18
19{\small \begin{verbatim}
20typedef unsigned short secondTy;
21\end{verbatim}}
22
23{\small \begin{verbatim}
24typedef unsigned long clockTy;
25\end{verbatim}}
26
27{\small \begin{verbatim}
28enum tFormat { wx12h, wx24h };
29\end{verbatim}}
30
31{\small \begin{verbatim}
32enum tPrecision { wxStdMinSec, wxStdMin };
33\end{verbatim}}
34
a660d684
KB
35\wxheading{See also}
36
37\helpref{wxDate}{wxDate}
38
39\latexignore{\rtfignore{\wxheading{Members}}}
40
ce3ed50d
JS
41\membersection{wxTime::wxTime}\label{wxtimewxtime}
42
43\func{}{wxTime}{\void}
44
45Initialize the object using the current time.
46
47\func{}{wxTime}{\param{clockTy }{s}}
48
49Initialize the object using the number of seconds that have elapsed since ???.
50
51\func{}{wxTime}{\param{const wxTime\&}{ time}}
52
53Copy constructor.
54
55\func{}{wxTime}{\param{hourTy }{h}, \param{minuteTy }{m}, \param{secondTy }{s = 0}, \param{bool }{dst = FALSE}}
56
57Initialize using hours, minutes, seconds, and whether DST time.
58
ce3ed50d
JS
59\func{}{wxTime}{\param{const wxDate\&}{ date}, \param{hourTy }{h = 0}, \param{minuteTy }{m = 0}, \param{secondTy }{s = 0}, \param{bool }{dst = FALSE}}
60
61Initialize using a \helpref{wxDate}{wxdate} object, hours, minutes, seconds, and whether DST time.
62
63\membersection{wxTime::GetDay}\label{wxtimegetday}
64
65\constfunc{int}{GetDay}{\void}
66
67Returns the day of the month.
68
69\membersection{wxTime::GetDayOfWeek}\label{wxtimegetdatofweek}
70
71\constfunc{int}{GetDayOfWeek}{\void}
72
73Returns the day of the week, a number from 0 to 6 where 0 is Sunday and 6 is Saturday.
74
75\membersection{wxTime::GetHour}\label{wxtimegethour}
76
77\constfunc{hourTy}{GetHour}{\void}
78
79Returns the hour in local time.
80
81\membersection{wxTime::GetHourGMT}\label{wxtimegethourgmt}
82
83\constfunc{hourTy}{GetHourGMT}{\void}
84
85Returns the hour in GMT.
86
87\membersection{wxTime::GetMinute}\label{wxtimegetminute}
88
89\constfunc{minuteTy}{GetMinute}{\void}
90
91Returns the minute in local time.
92
93\membersection{wxTime::GetMinuteGMT}\label{wxtimegetminutegmt}
94
95\constfunc{minuteTy}{GetMinuteGMT}{\void}
96
97Returns the minute in GMT.
98
99\membersection{wxTime::GetMonth}\label{wxtimegetmonth}
100
101\constfunc{int}{GetMonth}{\void}
102
103Returns the month.
104
105\membersection{wxTime::GetSecond}\label{wxtimegetsecond}
106
107\constfunc{secondTy}{GetSecond}{\void}
108
109Returns the second in local time or GMT.
110
111\membersection{wxTime::GetSecondGMT}\label{wxtimegetsecondgmt}
112
113\constfunc{secondTy}{GetSecondGMT}{\void}
114
115Returns the second in GMT.
116
117\membersection{wxTime::GetSeconds}\label{wxtimegetseconds}
118
119\constfunc{clockTy}{GetSeconds}{\void}
120
121Returns the number of seconds since ???.
122
123\membersection{wxTime::GetYear}\label{wxtimegetyear}
124
125\constfunc{int}{GetYear}{\void}
126
127Returns the year.
128
129\membersection{wxTime::FormatTime}\label{wxtimeformattime}
130
131\constfunc{char*}{FormatTime}{\void}
132
133Formats the time according to the current formatting options: see \helpref{wxTime::SetFormat}{wxtimesetformat}.
134
135\membersection{wxTime::IsBetween}\label{wxtimeisbetween}
136
137\constfunc{bool}{IsBetween}{\param{const wxTime\& }{a}, \param{const wxTime\& }{b}}
138
139Returns TRUE if this time is between the two given times.
140
141\membersection{wxTime::Max}\label{wxtimemax}
142
143\constfunc{wxTime}{Max}{\param{const wxTime\& }{time}}
144
145Returns the maximum of the two times.
146
147\membersection{wxTime::Min}\label{wxtimemin}
148
149\constfunc{wxTime}{Min}{\param{const wxTime\& }{time}}
150
151Returns the minimum of the two times.
152
153\membersection{wxTime::SetFormat}\label{wxtimesetformat}
154
155\func{static void}{SetFormat}{\param{const tFormat}{ format = wx12h},
156 \param{const tPrecision}{ precision = wxStdMinSec}}
157
158Sets the format and precision.
159
160\membersection{wxTime::operator char*}\label{wxtimestring}
161
162\func{operator}{char*}{\void}
163
164Returns a pointer to a static char* containing the formatted time.
165
166\membersection{wxTime::operator wxDate}\label{wxtimewxdate}
167
168\constfunc{operator}{wxDate}{\void}
169
170Converts the wxTime into a wxDate.
171
172\membersection{wxTime::operator $=$}\label{wxtimeoperator}
173
174\func{void}{operator $=$}{\param{const wxTime\& }{t}}
175
176Assignment operator.
177
178\membersection{wxTime::operator $<$}\label{wxtimeoperatorle}
179
180\constfunc{bool}{operator $<$}{\param{const wxTime\& }{t}}
181
182Less than operator.
183
184\membersection{wxTime::operator $<=$}\label{wxtimeoperatorleq}
185
186\constfunc{bool}{operator $<=$}{\param{const wxTime\& }{t}}
187
188Less than or equal to operator.
189
190\membersection{wxTime::operator $>$}\label{wxtimeoperatorge}
191
192\constfunc{bool}{operator $>$}{\param{const wxTime\& }{t}}
193
194Greater than operator.
195
196\membersection{wxTime::operator $>=$}\label{wxtimeoperatorgeq}
197
198\constfunc{bool}{operator $>=$}{\param{const wxTime\& }{t}}
199
200Greater than or equal to operator.
201
202\membersection{wxTime::operator $==$}\label{wxtimeoperatoreq}
203
204\constfunc{bool}{operator $==$}{\param{const wxTime\& }{t}}
205
206Equality operator.
207
208\membersection{wxTime::operator $!=$}\label{wxtimeoperatorneq}
209
210\constfunc{bool}{operator $!=$}{\param{const wxTime\& }{t}}
211
212Inequality operator.
213
214\membersection{wxTime::operator $+$}\label{wxtimeoperatorplus}
215
216\constfunc{bool}{operator $+$}{\param{long }{sec}}
217
218Addition operator.
219
220\membersection{wxTime::operator $-$}\label{wxtimeoperatorminus}
221
222\constfunc{bool}{operator $-$}{\param{long }{sec}}
223
224Subtraction operator.
225
226\membersection{wxTime::operator $+=$}\label{wxtimeoperatorpluseq}
227
228\constfunc{bool}{operator $+=$}{\param{long }{sec}}
229
230Increment operator.
231
232\membersection{wxTime::operator $-=$}\label{wxtimeoperatorminuseq}
233
234\constfunc{bool}{operator $-=$}{\param{long }{sec}}
235
236Decrement operator.
a660d684 237