]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/clientdat.tex
Reversed the meaning of black and white in wxRegion::ConvertToBitmap
[wxWidgets.git] / docs / latex / wx / clientdat.tex
CommitLineData
e3ba9f88
RR
1\section{\class{wxClientData}}\label{wxclientdata}
2
3All classes deriving from \helpref{wxEvtHandler}{wxevthandler}
4(such as all controls and \helpref{wxApp}{wxapp})
5can hold arbitrary data which is here referred to as "client data".
6This is useful e.g. for scripting languages which need to handle
7shadow objects for most of wxWindows' classes and which store
8a handle to such a shadow class as client data in that class.
9This data can either be of type void - in which case the data
10{\it container} does not take care of freeing the data again
11or it is of type wxClientData or its derivates. In that case the
12container (e.g. a control) will free the memory itself later.
13Note that you {\it must not} assign both void data and data
14derived from the wxClientData class to a container.
15
16Some controls can hold various items and these controls can
17additionally hold client data for each item. This is the case for
18\helpref{wxChoice}{wxchoice}, \helpref{wxComboBox}{wxcombobox}
19and \helpref{wxListBox}{wxlistbox}. \helpref{wxTreeCtrl}{wxtreectrl}
20has a specialized class \helpref{wxTreeItemData}{wxtreeitemdata}
21for each item in the tree.
22
23If you want to add client data to your own classes, you may
24use the mix-in class \helpref{wxClientDataContainer}{wxclientdatacontainer}.
25
26\wxheading{Include files}
27
28<wx/clntdata.h>
29
30\wxheading{See also}
31
32\helpref{wxEvtHandler}{wxevthandler}, \helpref{wxTreeItemData}{wxtreeitemdata},
33\helpref{wxStringClientData}{wxstringclientdata}, \helpref{wxClientDataContainer}{wxclientdatacontainer}
34
35\latexignore{\rtfignore{\wxheading{Members}}}
36
37
38\membersection{wxClientData::wxClientData}\label{wxclientdatawxclientdata}
39
40\func{}{wxClientData}{\void}
41
42Constructor.
43
44\membersection{wxClientData::\destruct{wxClientData}}\label{wxclientdatadtor}
45
46\func{}{\destruct{wxClientData}}{\void}
47
48Virtual destructor.
49
50\section{\class{wxClientDataContainer}}\label{wxclientdatacontainer}
51
52This class is a mixin that provides storage and management of "client
53data." This data can either be of type void - in which case the data
54{\it container} does not take care of freeing the data again
55or it is of type wxClientData or its derivates. In that case the
56container will free the memory itself later.
57Note that you {\it must not} assign both void data and data
58derived from the wxClientData class to a container.
59
60NOTE: This functionality is currently duplicated in wxEvtHandler in
61order to avoid having more than one vtable in that class heirachy.
62
63\wxheading{See also}
64
65\helpref{wxEvtHandler}{wxevthandler}, \helpref{wxClientData}{wxclientdata}
66
67\wxheading{Derived from}
68
69No base class
70
71\wxheading{Include files}
72
73<clntdata.h>
74
75\wxheading{Data structures}
76
77\latexignore{\rtfignore{\wxheading{Members}}}
78
79
80\membersection{wxClientDataContainer::wxClientDataContainer}\label{wxclientdatacontainerwxclientdatacontainer}
81
82\func{}{wxClientDataContainer}{\void}
83
84
85\membersection{wxClientDataContainer::\destruct{wxClientDataContainer}}\label{wxclientdatacontainerdtor}
86
87\func{}{\destruct{wxClientDataContainer}}{\void}
88
89
90\membersection{wxClientDataContainer::GetClientData}\label{wxclientdatacontainergetclientdata}
91
92\constfunc{void*}{GetClientData}{\void}
93
94Get the untyped client data.
95
96\membersection{wxClientDataContainer::GetClientObject}\label{wxclientdatacontainergetclientobject}
97
98\constfunc{wxClientData*}{GetClientObject}{\void}
99
100Get a pointer to the client data object.
101
102\membersection{wxClientDataContainer::SetClientData}\label{wxclientdatacontainersetclientdata}
103
104\func{void}{SetClientData}{\param{void* }{data}}
105
106Set the untyped client data.
107
108\membersection{wxClientDataContainer::SetClientObject}\label{wxclientdatacontainersetclientobject}
109
110\func{void}{SetClientObject}{\param{wxClientData* }{data}}
111
112Set the client data object. Any previous object will be deleted.
113