File: wx271.htm

package info (click to toggle)
wxwin2-doc 2.01-1
  • links: PTS
  • area: main
  • in suites: potato
  • size: 6,540 kB
  • ctags: 5,968
  • sloc: cpp: 15,157; makefile: 434; sh: 6
file content (728 lines) | stat: -rw-r--r-- 28,524 bytes parent folder | download
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
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
<HTML>
<head><title>Miscellaneous functions</title></head>

<BODY BGCOLOR=#FFFFFF>
<A NAME="miscellany"></A><CENTER>
<A HREF="wx.htm"><img align=center src="contents.gif" BORDER=0 ALT="Contents"></A> <A HREF="wx264.htm#functions"><img align=center src="up.gif" BORDER=0 ALT="Up"></A> <A HREF="wx270.htm#clipsboard"><img align=center src="back.gif" BORDER=0 ALT="Previous"></A> <A HREF="wx272.htm#macros"><img align=center src="forward.gif" BORDER=0 ALT="Next"></A> </CENTER><HR>

<H2>Miscellaneous functions</H2>
<P>
<A HREF="#topic1091">::wxNewId</A><BR>
<A HREF="#topic1092">::wxRegisterId</A><BR>
<A HREF="#wxbeginbusycursor">::wxBeginBusyCursor</A><BR>
<A HREF="#topic1093">::wxBell</A><BR>
<A HREF="#wxcreatedynamicobject">::wxCreateDynamicObject</A><BR>
<A HREF="#wxddecleanup">::wxDDECleanUp</A><BR>
<A HREF="#wxddeinitialize">::wxDDEInitialize</A><BR>
<A HREF="#wxdebugmsg">::wxDebugMsg</A><BR>
<A HREF="#topic1094">::wxDisplaySize</A><BR>
<A HREF="#wxentry">::wxEntry</A><BR>
<A HREF="#wxerror">::wxError</A><BR>
<A HREF="#wxendbusycursor">::wxEndBusyCursor</A><BR>
<A HREF="#wxexecute">::wxExecute</A><BR>
<A HREF="#wxexit">::wxExit</A><BR>
<A HREF="#wxfatalerror">::wxFatalError</A><BR>
<A HREF="#topic1095">::wxFindMenuItemId</A><BR>
<A HREF="#topic1096">::wxFindWindowByLabel</A><BR>
<A HREF="#wxfindwindowbyname">::wxFindWindowByName</A><BR>
<A HREF="#wxgetactivewindow">::wxGetActiveWindow</A><BR>
<A HREF="#wxgetdisplayname">::wxGetDisplayName</A><BR>
<A HREF="#topic1097">::wxGetHomeDir</A><BR>
<A HREF="#topic1098">::wxGetHostName</A><BR>
<A HREF="#wxgetelapsedtime">::wxGetElapsedTime</A><BR>
<A HREF="#wxgetfreememory">::wxGetFreeMemory</A><BR>
<A HREF="#topic1099">::wxGetMousePosition</A><BR>
<A HREF="#topic1100">::wxGetOsVersion</A><BR>
<A HREF="#wxgetresource">::wxGetResource</A><BR>
<A HREF="#topic1101">::wxGetUserId</A><BR>
<A HREF="#topic1102">::wxGetUserName</A><BR>
<A HREF="#wxkill">::wxKill</A><BR>
<A HREF="#wxisbusy">::wxIsBusy</A><BR>
<A HREF="#wxloaduserresource">::wxLoadUserResource</A><BR>
<A HREF="#wxnow">::wxNow</A><BR>
<A HREF="#wxpostdelete">::wxPostDelete</A><BR>
<A HREF="#wxsetdisplayname">::wxSetDisplayName</A><BR>
<A HREF="#wxshell">::wxShell</A><BR>
<A HREF="#wxsleep">::wxSleep</A><BR>
<A HREF="#topic1103">::wxStripMenuCodes</A><BR>
<A HREF="#wxstarttimer">::wxStartTimer</A><BR>
<A HREF="#wxtolower">::wxToLower</A><BR>
<A HREF="#wxtoupper">::wxToUpper</A><BR>
<A HREF="#wxtrace">::wxTrace</A><BR>
<A HREF="#wxtracelevel">::wxTraceLevel</A><BR>
<A HREF="#wxwriteresource">::wxWriteResource</A><BR>
<A HREF="#wxyield">::wxYield</A><BR>
<P>

<HR>
<A NAME="topic1091"></A>
<H3>::wxNewId</H3>
<P>
<B>long</B> <B>wxNewId</B>()<P>
Generates an integer identifier unique to this run of the program.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="topic1092"></A>
<H3>::wxRegisterId</H3>
<P>
<B>void</B> <B>wxRegisterId</B>(<B>long</B><I> id</I>)<P>
Ensures that ids subsequently generated by <B>NewId</B> do not clash with
the given <B>id</B>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxbeginbusycursor"></A>
<H3>::wxBeginBusyCursor</H3>
<P>
<B>void</B> <B>wxBeginBusyCursor</B>(<B>wxCursor *</B><I>cursor = wxHOURGLASS_CURSOR</I>)<P>
Changes the cursor to the given cursor for all windows in the application.
Use <A HREF="wx271.htm#wxendbusycursor">wxEndBusyCursor</A> to revert the cursor back
to its previous state. These two calls can be nested, and a counter
ensures that only the outer calls take effect.<P>
See also <A HREF="wx271.htm#wxisbusy">wxIsBusy</A>, <A HREF="wx30.htm#wxbusycursor">wxBusyCursor</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="topic1093"></A>
<H3>::wxBell</H3>
<P>
<B>void</B> <B>wxBell</B>()<P>
Ring the system bell.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxcreatedynamicobject"></A>
<H3>::wxCreateDynamicObject</H3>
<P>
<B>wxObject *</B> <B>wxCreateDynamicObject</B>(<B>const wxString&amp; </B><I>className</I>)<P>
Creates and returns an object of the given class, if the class has been
registered with the dynamic class system using DECLARE... and IMPLEMENT... macros.<P>

<HR>
<A NAME="wxddecleanup"></A>
<H3>::wxDDECleanUp</H3>
<P>
<B>void</B> <B>wxDDECleanUp</B>()<P>
Called when wxWindows exits, to clean up the DDE system. This no longer needs to be
called by the application.<P>
See also helprefwxDDEInitializewxddeinitialize.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/dde.h&gt;<P>

<HR>
<A NAME="wxddeinitialize"></A>
<H3>::wxDDEInitialize</H3>
<P>
<B>void</B> <B>wxDDEInitialize</B>()<P>
Initializes the DDE system. May be called multiple times without harm.<P>
This no longer needs to be called by the application: it will be called
by wxWindows if necessary.<P>
See also <A HREF="wx68.htm#wxddeserver">wxDDEServer</A>, <A HREF="wx66.htm#wxddeclient">wxDDEClient</A>, <A HREF="wx67.htm#wxddeconnection">wxDDEConnection</A>, 
<A HREF="wx271.htm#wxddecleanup">wxDDECleanUp</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/dde.h&gt;<P>

<HR>
<A NAME="wxdebugmsg"></A>
<H3>::wxDebugMsg</H3>
<P>
<B>void</B> <B>wxDebugMsg</B>(<B>const wxString&amp; </B><I>fmt</I>, <B>...</B><I></I>)<P>
Display a debugging message; under Windows, this will appear on the
debugger command window, and under Unix, it will be written to standard
error.<P>
The syntax is identical to <B>printf</B>: pass a format string and a
variable list of arguments.<P>
Note that under Windows, you can see the debugging messages without a
debugger if you have the DBWIN debug log application that comes with
Microsoft C++.<P>
<B>Tip:</B> under Windows, if your application crashes before the
message appears in the debugging window, put a wxYield call after
each wxDebugMsg call. wxDebugMsg seems to be broken under WIN32s
(at least for Watcom C++): preformat your messages and use OutputDebugString
instead.<P>
This function is now obsolete, replaced by <A HREF="wx274.htm#logfunctions">Log functions</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="topic1094"></A>
<H3>::wxDisplaySize</H3>
<P>
<B>void</B> <B>wxDisplaySize</B>(<B>int *</B><I>width</I>, <B>int *</B><I>height</I>)<P>
Gets the physical size of the display in pixels.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/gdicmn.h&gt;<P>

<HR>
<A NAME="wxentry"></A>
<H3>::wxEntry</H3>
<P>
This initializes wxWindows in a platform-dependent way. Use this if you
are not using the default wxWindows entry code (e.g. main or WinMain). For example,
you can initialize wxWindows from an Microsoft Foundation Classes application using
this function.<P>
<B>void</B> <B>wxEntry</B>(<B>HANDLE</B><I> hInstance</I>, <B>HANDLE</B><I> hPrevInstance</I>,
 <B>const wxString&amp; </B><I>commandLine</I>, <B>int</B><I> cmdShow</I>, <B>bool</B><I> enterLoop = TRUE</I>)<P>
wxWindows initialization under Windows (non-DLL). If <I>enterLoop</I> is FALSE, the
function will return immediately after calling wxApp::OnInit. Otherwise, the wxWindows
message loop will be entered.<P>
<B>void</B> <B>wxEntry</B>(<B>HANDLE</B><I> hInstance</I>, <B>HANDLE</B><I> hPrevInstance</I>,
 <B>WORD</B><I> wDataSegment</I>, <B>WORD</B><I> wHeapSize</I>, <B>const wxString&amp; </B><I> commandLine</I>)<P>
wxWindows initialization under Windows (for applications constructed as a DLL).<P>
<B>int</B> <B>wxEntry</B>(<B>int</B><I> argc</I>, <B>const wxString&amp; *</B><I>argv</I>)<P>
wxWindows initialization under Unix.<P>
<B><FONT COLOR="#FF0000">Remarks</FONT></B><P>
To clean up wxWindows, call wxApp::OnExit followed by the static function
wxApp::CleanUp. For example, if exiting from an MFC application that also uses wxWindows:<P>
<PRE>
int CTheApp::ExitInstance()
{
  // OnExit isn't called by CleanUp so must be called explicitly.
  wxTheApp-&gt;OnExit();
  wxApp::CleanUp();

  return CWinApp::ExitInstance();
}
</PRE>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/app.h&gt;<P>

<HR>
<A NAME="wxerror"></A>
<H3>::wxError</H3>
<P>
<B>void</B> <B>wxError</B>(<B>const wxString&amp; </B><I>msg</I>, <B>const wxString&amp; </B><I>title = "wxWindows Internal Error"</I>)<P>
Displays <I>msg</I> and continues. This writes to standard error under
Unix, and pops up a message box under Windows. Used for internal
wxWindows errors. See also <A HREF="wx271.htm#wxfatalerror">wxFatalError</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxendbusycursor"></A>
<H3>::wxEndBusyCursor</H3>
<P>
<B>void</B> <B>wxEndBusyCursor</B>()<P>
Changes the cursor back to the original cursor, for all windows in the application.
Use with <A HREF="wx271.htm#wxbeginbusycursor">wxBeginBusyCursor</A>.<P>
See also <A HREF="wx271.htm#wxisbusy">wxIsBusy</A>, <A HREF="wx30.htm#wxbusycursor">wxBusyCursor</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxexecute"></A>
<H3>::wxExecute</H3>
<P>
<B>long</B> <B>wxExecute</B>(<B>const wxString&amp; </B><I>command</I>, <B>bool </B><I>sync = FALSE</I>, <B>wxProcess *</B><I>callback = NULL</I>)<P>
<B>long</B> <B>wxExecute</B>(<B>char **</B><I>argv</I>, <B>bool </B><I>sync = FALSE</I>, <B>wxProcess *</B><I>callback = NULL</I>)<P>
Executes another program in Unix or Windows.<P>
The first form takes a command string, such as <TT>"emacs file.txt"</TT>.<P>
The second form takes an array of values: a command, any number of
arguments, terminated by NULL.<P>
If <I>sync</I> is FALSE (the default), flow of control immediately returns.
If TRUE, the current application waits until the other program has terminated.<P>
In the case of synchronous execution, the return value is trhe exit code of
the process (which terminates by the moment the function returns) and will be
-1 if the process couldn't be started and typically 0 if the process
terminated successfully.<P>
For asynchronous execution, however, the return value is the process id and
zero value indicates that the command could not be executed.<P>
If callback isn't NULL and if execution is asynchronous (note that callback
parameter can not be non NULL for synchronous execution), 
<A HREF="wx184.htm#wxprocessonterminate">wxProcess::OnTerminate</A> will be called when
the process finishes.<P>
See also <A HREF="wx271.htm#wxshell">wxShell</A>, <A HREF="wx184.htm#wxprocess">wxProcess</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxexit"></A>
<H3>::wxExit</H3>
<P>
<B>void</B> <B>wxExit</B>()<P>
Exits application after calling <A HREF="wx26.htm#wxapponexit">wxApp::OnExit</A>.
Should only be used in an emergency: normally the top-level frame
should be deleted (after deleting all other frames) to terminate the
application. See <A HREF="wx260.htm#wxwindowonclosewindow">wxWindow::OnCloseWindow</A> and <A HREF="wx26.htm#wxapp">wxApp</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/app.h&gt;<P>

<HR>
<A NAME="wxfatalerror"></A>
<H3>::wxFatalError</H3>
<P>
<B>void</B> <B>wxFatalError</B>(<B>const wxString&amp; </B><I>msg</I>, <B>const wxString&amp; </B><I>title = "wxWindows Fatal Error"</I>)<P>
Displays <I>msg</I> and exits. This writes to standard error under Unix,
and pops up a message box under Windows. Used for fatal internal
wxWindows errors. See also <A HREF="wx271.htm#wxerror">wxError</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="topic1095"></A>
<H3>::wxFindMenuItemId</H3>
<P>
<B>int</B> <B>wxFindMenuItemId</B>(<B>wxFrame *</B><I>frame</I>, <B>const wxString&amp; </B><I>menuString</I>, <B>const wxString&amp; </B><I>itemString</I>)<P>
Find a menu item identifier associated with the given frame's menu bar.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="topic1096"></A>
<H3>::wxFindWindowByLabel</H3>
<P>
<B>wxWindow *</B> <B>wxFindWindowByLabel</B>(<B>const wxString&amp; </B><I>label</I>, <B>wxWindow *</B><I>parent=NULL</I>)<P>
Find a window by its label. Depending on the type of window, the label may be a window title
or panel item label. If <I>parent</I> is NULL, the search will start from all top-level
frames and dialog boxes; if non-NULL, the search will be limited to the given window hierarchy.
The search is recursive in both cases.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxfindwindowbyname"></A>
<H3>::wxFindWindowByName</H3>
<P>
<B>wxWindow *</B> <B>wxFindWindowByName</B>(<B>const wxString&amp; </B><I>name</I>, <B>wxWindow *</B><I>parent=NULL</I>)<P>
Find a window by its name (as given in a window constructor or <B>Create</B> function call).
If <I>parent</I> is NULL, the search will start from all top-level
frames and dialog boxes; if non-NULL, the search will be limited to the given window hierarchy.
The search is recursive in both cases.<P>
If no such named window is found, <B>wxFindWindowByLabel</B> is called.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxgetactivewindow"></A>
<H3>::wxGetActiveWindow</H3>
<P>
<B>wxWindow *</B> <B>wxGetActiveWindow</B>()<P>
Gets the currently active window (Windows only).<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/windows.h&gt;<P>

<HR>
<A NAME="wxgetdisplayname"></A>
<H3>::wxGetDisplayName</H3>
<P>
<B>wxString</B> <B>wxGetDisplayName</B>()<P>
Under X only, returns the current display name. See also <A HREF="wx271.htm#wxsetdisplayname">wxSetDisplayName</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="topic1097"></A>
<H3>::wxGetHomeDir</H3>
<P>
<B>wxString</B> <B>wxGetHomeDir</B>(<B>const wxString&amp; </B><I>buf</I>)<P>
Fills the buffer with a string representing the user's home directory (Unix only).<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="topic1098"></A>
<H3>::wxGetHostName</H3>
<P>
<B>bool</B> <B>wxGetHostName</B>(<B>const wxString&amp; </B><I>buf</I>, <B>int</B><I> bufSize</I>)<P>
Copies the host name of the machine the program is running on into the
buffer <I>buf</I>, of maximum size <I>bufSize</I>, returning TRUE if
successful. Under Unix, this will return a machine name. Under Windows,
this returns "windows''.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxgetelapsedtime"></A>
<H3>::wxGetElapsedTime</H3>
<P>
<B>long</B> <B>wxGetElapsedTime</B>(<B>bool</B><I> resetTimer = TRUE</I>)<P>
Gets the time in milliseconds since the last <A HREF="wx271.htm#wxstarttimer">::wxStartTimer</A>.<P>
If <I>resetTimer</I> is TRUE (the default), the timer is reset to zero
by this call.<P>
See also <A HREF="wx248.htm#wxtimer">wxTimer</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/timer.h&gt;<P>

<HR>
<A NAME="wxgetfreememory"></A>
<H3>::wxGetFreeMemory</H3>
<P>
<B>long</B> <B>wxGetFreeMemory</B>()<P>
Returns the amount of free memory in Kbytes under environments which
support it, and -1 if not supported. Currently, returns a positive value
under Windows, and -1 under Unix.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="topic1099"></A>
<H3>::wxGetMousePosition</H3>
<P>
<B>void</B> <B>wxGetMousePosition</B>(<B>int* </B><I>x</I>, <B>int* </B><I>y</I>)<P>
Returns the mouse position in screen coordinates.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="topic1100"></A>
<H3>::wxGetOsVersion</H3>
<P>
<B>int</B> <B>wxGetOsVersion</B>(<B>int *</B><I>major = NULL</I>, <B>int *</B><I>minor = NULL</I>)<P>
Gets operating system version information.<P>

<TABLE>


<TR><TD VALIGN=TOP>
Platform
</TD>

<TD VALIGN=TOP>
Return tyes
</TD></TR>


<TR><TD VALIGN=TOP>
Macintosh
</TD>

<TD VALIGN=TOP>
Return value is wxMACINTOSH.
</TD></TR>


<TR><TD VALIGN=TOP>
GTK
</TD>

<TD VALIGN=TOP>
Return value is wxGTK, <I>major</I> is 1, <I>minor</I> is 0. (for GTK 1.0.X) 
</TD></TR>


<TR><TD VALIGN=TOP>
Motif
</TD>

<TD VALIGN=TOP>
Return value is wxMOTIF_X, <I>major</I> is X version, <I>minor</I> is X revision.
</TD></TR>


<TR><TD VALIGN=TOP>
OS/2
</TD>

<TD VALIGN=TOP>
Return value is wxOS2_PM.
</TD></TR>


<TR><TD VALIGN=TOP>
Windows 3.1
</TD>

<TD VALIGN=TOP>
Return value is wxWINDOWS, <I>major</I> is 3, <I>minor</I> is 1.
</TD></TR>


<TR><TD VALIGN=TOP>
Windows NT
</TD>

<TD VALIGN=TOP>
Return value is wxWINDOWS_NT, <I>major</I> is 3, <I>minor</I> is 1.
</TD></TR>


<TR><TD VALIGN=TOP>
Windows 95
</TD>

<TD VALIGN=TOP>
Return value is wxWIN95, <I>major</I> is 3, <I>minor</I> is 1.
</TD></TR>


<TR><TD VALIGN=TOP>
Win32s (Windows 3.1)
</TD>

<TD VALIGN=TOP>
Return value is wxWIN32S, <I>major</I> is 3, <I>minor</I> is 1.
</TD></TR>


<TR><TD VALIGN=TOP>
Watcom C++ 386 supervisor mode (Windows 3.1)
</TD>

<TD VALIGN=TOP>
Return value is wxWIN386, <I>major</I> is 3, <I>minor</I> is 1.
</TD></TR>


</TABLE>
<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxgetresource"></A>
<H3>::wxGetResource</H3>
<P>
<B>bool</B> <B>wxGetResource</B>(<B>const wxString&amp; </B><I>section</I>, <B>const wxString&amp; </B><I>entry</I>,
 <B>const wxString&amp; *</B><I>value</I>, <B>const wxString&amp; </B><I>file = NULL</I>)<P>
<B>bool</B> <B>wxGetResource</B>(<B>const wxString&amp; </B><I>section</I>, <B>const wxString&amp; </B><I>entry</I>,
 <B>float *</B><I>value</I>, <B>const wxString&amp; </B><I>file = NULL</I>)<P>
<B>bool</B> <B>wxGetResource</B>(<B>const wxString&amp; </B><I>section</I>, <B>const wxString&amp; </B><I>entry</I>,
 <B>long *</B><I>value</I>, <B>const wxString&amp; </B><I>file = NULL</I>)<P>
<B>bool</B> <B>wxGetResource</B>(<B>const wxString&amp; </B><I>section</I>, <B>const wxString&amp; </B><I>entry</I>,
 <B>int *</B><I>value</I>, <B>const wxString&amp; </B><I>file = NULL</I>)<P>
Gets a resource value from the resource database (for example, WIN.INI, or
.Xdefaults). If <I>file</I> is NULL, WIN.INI or .Xdefaults is used,
otherwise the specified file is used.<P>
Under X, if an application class (wxApp::GetClassName) has been defined,
it is appended to the string /usr/lib/X11/app-defaults/ to try to find
an applications default file when merging all resource databases.<P>
The reason for passing the result in an argument is that it
can be convenient to define a default value, which gets overridden
if the value exists in the resource file. It saves a separate
test for that resource's existence, and it also allows
the overloading of the function for different types.<P>
See also <A HREF="wx271.htm#wxwriteresource">wxWriteResource</A>, <A HREF="wx55.htm#wxconfigbase">wxConfigBase</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="topic1101"></A>
<H3>::wxGetUserId</H3>
<P>
<B>bool</B> <B>wxGetUserId</B>(<B>const wxString&amp; </B><I>buf</I>, <B>int</B><I> bufSize</I>)<P>
Copies the user's login identity (such as "jacs'') into the buffer <I>
buf</I>, of maximum size <I>bufSize</I>, returning TRUE if successful.
Under Windows, this returns "user''.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="topic1102"></A>
<H3>::wxGetUserName</H3>
<P>
<B>bool</B> <B>wxGetUserName</B>(<B>const wxString&amp; </B><I>buf</I>, <B>int</B><I> bufSize</I>)<P>
Copies the user's name (such as "Julian Smart'') into the buffer <I>
buf</I>, of maximum size <I>bufSize</I>, returning TRUE if successful.
Under Windows, this returns "unknown''.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxkill"></A>
<H3>::wxKill</H3>
<P>
<B>int</B> <B>wxKill</B>(<B>long</B><I> pid</I>, <B>int</B><I> sig</I>)<P>
Under Unix (the only supported platform), equivalent to the Unix kill function.
Returns 0 on success, -1 on failure.<P>
Tip: sending a signal of 0 to a process returns -1 if the process does not exist.
It does not raise a signal in the receiving process.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxisbusy"></A>
<H3>::wxIsBusy</H3>
<P>
<B>bool</B> <B>wxIsBusy</B>()<P>
Returns TRUE if between two <A HREF="wx271.htm#wxbeginbusycursor">wxBeginBusyCursor</A> and
<A HREF="wx271.htm#wxendbusycursor">wxEndBusyCursor</A> calls.<P>
See also <A HREF="wx30.htm#wxbusycursor">wxBusyCursor</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxloaduserresource"></A>
<H3>::wxLoadUserResource</H3>
<P>
<B>wxString</B> <B>wxLoadUserResource</B>(<B>const wxString&amp; </B><I>resourceName</I>, <B>const wxString&amp; </B><I>resourceType="TEXT"</I>)<P>
Loads a user-defined Windows resource as a string. If the resource is found, the function creates
a new character array and copies the data into it. A pointer to this data is returned. If unsuccessful, NULL is returned.<P>
The resource must be defined in the <TT>.rc</TT> file using the following syntax:<P>
<PRE>
myResource TEXT file.ext
</PRE>
where <TT>file.ext</TT> is a file that the resource compiler can find.<P>
One use of this is to store <TT>.wxr</TT> files instead of including the data in the C++ file; some compilers
cannot cope with the long strings in a <TT>.wxr</TT> file. The resource data can then be parsed
using <A HREF="wx273.htm#wxresourceparsestring">wxResourceParseString</A>.<P>
This function is available under Windows only.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxnow"></A>
<H3>::wxNow</H3>
<P>
<B>wxString</B> <B>wxNow</B>()<P>
Returns a string representing the current date and time.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxpostdelete"></A>
<H3>::wxPostDelete</H3>
<P>
<B>void</B> <B>wxPostDelete</B>(<B>wxObject *</B><I>object</I>)<P>
Tells the system to delete the specified object when
all other events have been processed. In some environments, it is
necessary to use this instead of deleting a frame directly with the
delete operator, because some GUIs will still send events to a deleted window.<P>
Now obsolete: use <A HREF="wx260.htm#wxwindowclose">wxWindow::Close</A> instead.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxsetdisplayname"></A>
<H3>::wxSetDisplayName</H3>
<P>
<B>void</B> <B>wxSetDisplayName</B>(<B>const wxString&amp; </B><I>displayName</I>)<P>
Under X only, sets the current display name. This is the X host and display name such
as "colonsay:0.0", and the function indicates which display should be used for creating
windows from this point on. Setting the display within an application allows multiple
displays to be used.<P>
See also <A HREF="wx271.htm#wxgetdisplayname">wxGetDisplayName</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxshell"></A>
<H3>::wxShell</H3>
<P>
<B>bool</B> <B>wxShell</B>(<B>const wxString&amp; </B><I>command = NULL</I>)<P>
Executes a command in an interactive shell window. If no command is
specified, then just the shell is spawned.<P>
See also <A HREF="wx271.htm#wxexecute">wxExecute</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxsleep"></A>
<H3>::wxSleep</H3>
<P>
<B>void</B> <B>wxSleep</B>(<B>int</B><I> secs</I>)<P>
Sleeps for the specified number of seconds.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="topic1103"></A>
<H3>::wxStripMenuCodes</H3>
<P>
<B>wxString</B> <B>wxStripMenuCodes</B>(<B>const wxString&amp; </B><I>in</I>)<P>
<B>void</B> <B>wxStripMenuCodes</B>(<B>char* </B><I>in</I>, <B>char* </B><I>out</I>)<P>
Strips any menu codes from <I>in</I> and places the result
in <I>out</I> (or returns the new string, in the first form).<P>
Menu codes include &amp; (mark the next character with an underline
as a keyboard shortkey in Windows and Motif) and \t (tab in Windows).<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxstarttimer"></A>
<H3>::wxStartTimer</H3>
<P>
<B>void</B> <B>wxStartTimer</B>()<P>
Starts a stopwatch; use <A HREF="wx271.htm#wxgetelapsedtime">::wxGetElapsedTime</A> to get the elapsed time.<P>
See also <A HREF="wx248.htm#wxtimer">wxTimer</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/timer.h&gt;<P>

<HR>
<A NAME="wxtolower"></A>
<H3>::wxToLower</H3>
<P>
<B>char</B> <B>wxToLower</B>(<B>char </B><I>ch</I>)<P>
Converts the character to lower case. This is implemented as a macro for efficiency.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxtoupper"></A>
<H3>::wxToUpper</H3>
<P>
<B>char</B> <B>wxToUpper</B>(<B>char </B><I>ch</I>)<P>
Converts the character to upper case. This is implemented as a macro for efficiency.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxtrace"></A>
<H3>::wxTrace</H3>
<P>
<B>void</B> <B>wxTrace</B>(<B>const wxString&amp; </B><I>fmt</I>, <B>...</B><I></I>)<P>
Takes printf-style variable argument syntax. Output
is directed to the current output stream (see <A HREF="wx295.htm#wxdebugcontextoverview">wxDebugContext</A>).<P>
This function is now obsolete, replaced by <A HREF="wx274.htm#logfunctions">Log functions</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/memory.h&gt;<P>

<HR>
<A NAME="wxtracelevel"></A>
<H3>::wxTraceLevel</H3>
<P>
<B>void</B> <B>wxTraceLevel</B>(<B>int</B><I> level</I>, <B>const wxString&amp; </B><I>fmt</I>, <B>...</B><I></I>)<P>
Takes printf-style variable argument syntax. Output
is directed to the current output stream (see <A HREF="wx295.htm#wxdebugcontextoverview">wxDebugContext</A>).
The first argument should be the level at which this information is appropriate.
It will only be output if the level returned by wxDebugContext::GetLevel is equal to or greater than
this value.<P>
This function is now obsolete, replaced by <A HREF="wx274.htm#logfunctions">Log functions</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/memory.h&gt;<P>

<HR>
<A NAME="wxwriteresource"></A>
<H3>::wxWriteResource</H3>
<P>
<B>bool</B> <B>wxWriteResource</B>(<B>const wxString&amp; </B><I>section</I>, <B>const wxString&amp; </B><I>entry</I>,
 <B>const wxString&amp; </B><I>value</I>, <B>const wxString&amp; </B><I>file = NULL</I>)<P>
<B>bool</B> <B>wxWriteResource</B>(<B>const wxString&amp; </B><I>section</I>, <B>const wxString&amp; </B><I>entry</I>,
 <B>float </B><I>value</I>, <B>const wxString&amp; </B><I>file = NULL</I>)<P>
<B>bool</B> <B>wxWriteResource</B>(<B>const wxString&amp; </B><I>section</I>, <B>const wxString&amp; </B><I>entry</I>,
 <B>long </B><I>value</I>, <B>const wxString&amp; </B><I>file = NULL</I>)<P>
<B>bool</B> <B>wxWriteResource</B>(<B>const wxString&amp; </B><I>section</I>, <B>const wxString&amp; </B><I>entry</I>,
 <B>int </B><I>value</I>, <B>const wxString&amp; </B><I>file = NULL</I>)<P>
Writes a resource value into the resource database (for example, WIN.INI, or
.Xdefaults). If <I>file</I> is NULL, WIN.INI or .Xdefaults is used,
otherwise the specified file is used.<P>
Under X, the resource databases are cached until the internal function
<B>wxFlushResources</B> is called automatically on exit, when
all updated resource databases are written to their files.<P>
Note that it is considered bad manners to write to the .Xdefaults
file under Unix, although the WIN.INI file is fair game under Windows.<P>
See also <A HREF="wx271.htm#wxgetresource">wxGetResource</A>, <A HREF="wx55.htm#wxconfigbase">wxConfigBase</A>.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

<HR>
<A NAME="wxyield"></A>
<H3>::wxYield</H3>
<P>
<B>bool</B> <B>wxYield</B>()<P>
Yields control to pending messages in the windowing system. This can be useful, for example, when a
time-consuming process writes to a text window. Without an occasional
yield, the text window will not be updated properly, and (since Windows
multitasking is cooperative) other processes will not respond.<P>
Caution should be exercised, however, since yielding may allow the
user to perform actions which are not compatible with the current task.
Disabling menu items or whole menus during processing can avoid unwanted
reentrance of code.<P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/utils.h&gt;<P>

</BODY></HTML>