]> git.saurik.com Git - wxWidgets.git/blob - docs/latex/wx/strlist.tex
Corrected stupid error.
[wxWidgets.git] / docs / latex / wx / strlist.tex
1 \section{\class{wxStringList}}\label{wxstringlist}
2
3 A string list is a list which is assumed to contain strings.
4 Memory is allocated when strings are added to
5 the list, and deallocated by the destructor or by the {\bf Delete}\rtfsp
6 member.
7
8 \wxheading{Derived from}
9
10 \helpref{wxList}{wxlist}\\
11 \helpref{wxObject}{wxobject}
12
13 \wxheading{See also}
14
15 \helpref{wxString}{wxstring}, \helpref{wxList}{wxlist}
16
17 \latexignore{\rtfignore{\wxheading{Members}}}
18
19 \membersection{wxStringList::wxStringList}
20
21 \func{}{wxStringList}{\void}
22
23 Constructor.
24
25 \func{void}{wxStringList}{\param{char* }{first}, ...}
26
27 Constructor, taking NULL-terminated string argument list. wxStringList
28 allocates memory for the strings.
29
30 \membersection{wxStringList::\destruct{wxStringList}}
31
32 \func{}{\destruct{wxStringList}}{\void}
33
34 Deletes string list, deallocating strings.
35
36 \membersection{wxStringList::Add}
37
38 \func{wxNode *}{Add}{\param{const wxString\& }{s}}
39
40 Adds string to list, allocating memory.
41
42 \membersection{wxStringList::Clear}
43
44 \func{void}{Clear}{\void}
45
46 Clears all strings from the list.
47
48 \membersection{wxStringList::Delete}
49
50 \func{void}{Delete}{\param{const wxString\& }{s}}
51
52 Searches for string and deletes from list, deallocating memory.
53
54 \membersection{wxStringList::ListToArray}
55
56 \func{char*}{ListToArray}{\param{bool}{ new\_copies = FALSE}}
57
58 Converts the list to an array of strings, only allocating new memory if
59 \rtfsp{\bf new\_copies} is TRUE.
60
61 \membersection{wxStringList::Member}
62
63 \func{bool}{Member}{\param{const wxString\& }{s}}
64
65 Returns TRUE if {\bf s} is a member of the list (tested using {\bf strcmp}).
66
67 \membersection{wxStringList::Sort}
68
69 \func{void}{Sort}{\void}
70
71 Sorts the strings in ascending alphabetical order. Note that all nodes
72 (but not strings) get deallocated and new ones allocated.
73
74