]>
Commit | Line | Data |
---|---|---|
8ab979d7 RD |
1 | # This file was created automatically by SWIG. |
2 | import miscc | |
9416aa89 RD |
3 | class wxObjectPtr : |
4 | def __init__(self,this): | |
5 | self.this = this | |
6 | self.thisown = 0 | |
7 | def GetClassName(self, *_args, **_kwargs): | |
8 | val = apply(miscc.wxObject_GetClassName,(self,) + _args, _kwargs) | |
9 | return val | |
10 | def Destroy(self, *_args, **_kwargs): | |
11 | val = apply(miscc.wxObject_Destroy,(self,) + _args, _kwargs) | |
12 | return val | |
13 | def __repr__(self): | |
14 | return "<C wxObject instance at %s>" % (self.this,) | |
15 | class wxObject(wxObjectPtr): | |
16 | def __init__(self,this): | |
17 | self.this = this | |
18 | ||
19 | ||
20 | ||
21 | ||
8ab979d7 RD |
22 | class wxSizePtr : |
23 | def __init__(self,this): | |
24 | self.this = this | |
25 | self.thisown = 0 | |
7e50db3f RD |
26 | def __del__(self, delfunc=miscc.delete_wxSize): |
27 | if self.thisown == 1: | |
28 | try: | |
29 | delfunc(self) | |
30 | except: | |
31 | pass | |
1d99702e RD |
32 | def Set(self, *_args, **_kwargs): |
33 | val = apply(miscc.wxSize_Set,(self,) + _args, _kwargs) | |
8ab979d7 | 34 | return val |
1d99702e RD |
35 | def GetX(self, *_args, **_kwargs): |
36 | val = apply(miscc.wxSize_GetX,(self,) + _args, _kwargs) | |
af309447 | 37 | return val |
1d99702e RD |
38 | def GetY(self, *_args, **_kwargs): |
39 | val = apply(miscc.wxSize_GetY,(self,) + _args, _kwargs) | |
af309447 | 40 | return val |
1d99702e RD |
41 | def GetWidth(self, *_args, **_kwargs): |
42 | val = apply(miscc.wxSize_GetWidth,(self,) + _args, _kwargs) | |
8ab979d7 | 43 | return val |
1d99702e RD |
44 | def GetHeight(self, *_args, **_kwargs): |
45 | val = apply(miscc.wxSize_GetHeight,(self,) + _args, _kwargs) | |
8ab979d7 | 46 | return val |
1d99702e RD |
47 | def SetWidth(self, *_args, **_kwargs): |
48 | val = apply(miscc.wxSize_SetWidth,(self,) + _args, _kwargs) | |
bb0054cd | 49 | return val |
1d99702e RD |
50 | def SetHeight(self, *_args, **_kwargs): |
51 | val = apply(miscc.wxSize_SetHeight,(self,) + _args, _kwargs) | |
bb0054cd | 52 | return val |
1d99702e RD |
53 | def asTuple(self, *_args, **_kwargs): |
54 | val = apply(miscc.wxSize_asTuple,(self,) + _args, _kwargs) | |
8ab979d7 | 55 | return val |
7e50db3f RD |
56 | def __eq__(self, *_args, **_kwargs): |
57 | val = apply(miscc.wxSize___eq__,(self,) + _args, _kwargs) | |
58 | return val | |
59 | def __ne__(self, *_args, **_kwargs): | |
60 | val = apply(miscc.wxSize___ne__,(self,) + _args, _kwargs) | |
419c299a | 61 | return val |
8ab979d7 | 62 | def __setattr__(self,name,value): |
af309447 | 63 | if name == "x" : |
1d99702e | 64 | miscc.wxSize_x_set(self,value) |
af309447 RD |
65 | return |
66 | if name == "y" : | |
1d99702e | 67 | miscc.wxSize_y_set(self,value) |
af309447 | 68 | return |
8ab979d7 | 69 | if name == "width" : |
1d99702e | 70 | miscc.wxSize_width_set(self,value) |
8ab979d7 RD |
71 | return |
72 | if name == "height" : | |
1d99702e | 73 | miscc.wxSize_height_set(self,value) |
8ab979d7 RD |
74 | return |
75 | self.__dict__[name] = value | |
76 | def __getattr__(self,name): | |
af309447 | 77 | if name == "x" : |
1d99702e | 78 | return miscc.wxSize_x_get(self) |
af309447 | 79 | if name == "y" : |
1d99702e | 80 | return miscc.wxSize_y_get(self) |
8ab979d7 | 81 | if name == "width" : |
1d99702e | 82 | return miscc.wxSize_width_get(self) |
8ab979d7 | 83 | if name == "height" : |
1d99702e | 84 | return miscc.wxSize_height_get(self) |
8ab979d7 RD |
85 | raise AttributeError,name |
86 | def __repr__(self): | |
1d99702e | 87 | return "<C wxSize instance at %s>" % (self.this,) |
211a46cf RD |
88 | |
89 | def __str__(self): return str(self.asTuple()) | |
7e50db3f | 90 | def __repr__(self): return 'wxSize'+str(self.asTuple()) |
211a46cf RD |
91 | def __len__(self): return len(self.asTuple()) |
92 | def __getitem__(self, index): return self.asTuple()[index] | |
93 | def __setitem__(self, index, val): | |
94 | if index == 0: self.width = val | |
95 | elif index == 1: self.height = val | |
96 | else: raise IndexError | |
7e50db3f RD |
97 | def __nonzero__(self): return self.asTuple() != (0,0) |
98 | def __getinitargs__(self): return () | |
99 | def __getstate__(self): return self.asTuple() | |
100 | def __setstate__(self, state): self.Set(*state) | |
211a46cf | 101 | |
8ab979d7 | 102 | class wxSize(wxSizePtr): |
1d99702e RD |
103 | def __init__(self,*_args,**_kwargs): |
104 | self.this = apply(miscc.new_wxSize,_args,_kwargs) | |
8ab979d7 RD |
105 | self.thisown = 1 |
106 | ||
107 | ||
108 | ||
109 | ||
110 | class wxRealPointPtr : | |
111 | def __init__(self,this): | |
112 | self.this = this | |
113 | self.thisown = 0 | |
7e50db3f RD |
114 | def __del__(self, delfunc=miscc.delete_wxRealPoint): |
115 | if self.thisown == 1: | |
116 | try: | |
117 | delfunc(self) | |
118 | except: | |
119 | pass | |
efc5f224 RD |
120 | def Set(self, *_args, **_kwargs): |
121 | val = apply(miscc.wxRealPoint_Set,(self,) + _args, _kwargs) | |
122 | return val | |
123 | def asTuple(self, *_args, **_kwargs): | |
124 | val = apply(miscc.wxRealPoint_asTuple,(self,) + _args, _kwargs) | |
125 | return val | |
c368d904 RD |
126 | def __add__(self, *_args, **_kwargs): |
127 | val = apply(miscc.wxRealPoint___add__,(self,) + _args, _kwargs) | |
128 | if val: val = wxRealPointPtr(val) ; val.thisown = 1 | |
129 | return val | |
130 | def __sub__(self, *_args, **_kwargs): | |
131 | val = apply(miscc.wxRealPoint___sub__,(self,) + _args, _kwargs) | |
132 | if val: val = wxRealPointPtr(val) ; val.thisown = 1 | |
133 | return val | |
7e50db3f RD |
134 | def __eq__(self, *_args, **_kwargs): |
135 | val = apply(miscc.wxRealPoint___eq__,(self,) + _args, _kwargs) | |
136 | return val | |
137 | def __ne__(self, *_args, **_kwargs): | |
138 | val = apply(miscc.wxRealPoint___ne__,(self,) + _args, _kwargs) | |
c368d904 | 139 | return val |
8ab979d7 RD |
140 | def __setattr__(self,name,value): |
141 | if name == "x" : | |
1d99702e | 142 | miscc.wxRealPoint_x_set(self,value) |
8ab979d7 RD |
143 | return |
144 | if name == "y" : | |
1d99702e | 145 | miscc.wxRealPoint_y_set(self,value) |
8ab979d7 RD |
146 | return |
147 | self.__dict__[name] = value | |
148 | def __getattr__(self,name): | |
149 | if name == "x" : | |
1d99702e | 150 | return miscc.wxRealPoint_x_get(self) |
8ab979d7 | 151 | if name == "y" : |
1d99702e | 152 | return miscc.wxRealPoint_y_get(self) |
8ab979d7 RD |
153 | raise AttributeError,name |
154 | def __repr__(self): | |
1d99702e | 155 | return "<C wxRealPoint instance at %s>" % (self.this,) |
211a46cf RD |
156 | |
157 | def __str__(self): return str(self.asTuple()) | |
7e50db3f | 158 | def __repr__(self): return 'wxRealPoint'+str(self.asTuple()) |
211a46cf RD |
159 | def __len__(self): return len(self.asTuple()) |
160 | def __getitem__(self, index): return self.asTuple()[index] | |
161 | def __setitem__(self, index, val): | |
162 | if index == 0: self.width = val | |
163 | elif index == 1: self.height = val | |
164 | else: raise IndexError | |
7e50db3f RD |
165 | def __nonzero__(self): return self.asTuple() != (0.0, 0.0) |
166 | def __getinitargs__(self): return () | |
167 | def __getstate__(self): return self.asTuple() | |
168 | def __setstate__(self, state): self.Set(*state) | |
211a46cf | 169 | |
8ab979d7 | 170 | class wxRealPoint(wxRealPointPtr): |
1d99702e RD |
171 | def __init__(self,*_args,**_kwargs): |
172 | self.this = apply(miscc.new_wxRealPoint,_args,_kwargs) | |
8ab979d7 RD |
173 | self.thisown = 1 |
174 | ||
175 | ||
176 | ||
177 | ||
178 | class wxPointPtr : | |
179 | def __init__(self,this): | |
180 | self.this = this | |
181 | self.thisown = 0 | |
7e50db3f RD |
182 | def __del__(self, delfunc=miscc.delete_wxPoint): |
183 | if self.thisown == 1: | |
184 | try: | |
185 | delfunc(self) | |
186 | except: | |
187 | pass | |
1d99702e RD |
188 | def Set(self, *_args, **_kwargs): |
189 | val = apply(miscc.wxPoint_Set,(self,) + _args, _kwargs) | |
8ab979d7 | 190 | return val |
1d99702e RD |
191 | def asTuple(self, *_args, **_kwargs): |
192 | val = apply(miscc.wxPoint_asTuple,(self,) + _args, _kwargs) | |
8ab979d7 | 193 | return val |
c368d904 RD |
194 | def __add__(self, *_args, **_kwargs): |
195 | val = apply(miscc.wxPoint___add__,(self,) + _args, _kwargs) | |
196 | if val: val = wxPointPtr(val) ; val.thisown = 1 | |
197 | return val | |
198 | def __sub__(self, *_args, **_kwargs): | |
199 | val = apply(miscc.wxPoint___sub__,(self,) + _args, _kwargs) | |
200 | if val: val = wxPointPtr(val) ; val.thisown = 1 | |
201 | return val | |
7e50db3f RD |
202 | def __eq__(self, *_args, **_kwargs): |
203 | val = apply(miscc.wxPoint___eq__,(self,) + _args, _kwargs) | |
204 | return val | |
205 | def __ne__(self, *_args, **_kwargs): | |
206 | val = apply(miscc.wxPoint___ne__,(self,) + _args, _kwargs) | |
c368d904 | 207 | return val |
8ab979d7 RD |
208 | def __setattr__(self,name,value): |
209 | if name == "x" : | |
1d99702e | 210 | miscc.wxPoint_x_set(self,value) |
8ab979d7 RD |
211 | return |
212 | if name == "y" : | |
1d99702e | 213 | miscc.wxPoint_y_set(self,value) |
8ab979d7 RD |
214 | return |
215 | self.__dict__[name] = value | |
216 | def __getattr__(self,name): | |
217 | if name == "x" : | |
1d99702e | 218 | return miscc.wxPoint_x_get(self) |
8ab979d7 | 219 | if name == "y" : |
1d99702e | 220 | return miscc.wxPoint_y_get(self) |
8ab979d7 RD |
221 | raise AttributeError,name |
222 | def __repr__(self): | |
1d99702e | 223 | return "<C wxPoint instance at %s>" % (self.this,) |
211a46cf RD |
224 | |
225 | def __str__(self): return str(self.asTuple()) | |
7e50db3f | 226 | def __repr__(self): return 'wxPoint'+str(self.asTuple()) |
211a46cf RD |
227 | def __len__(self): return len(self.asTuple()) |
228 | def __getitem__(self, index): return self.asTuple()[index] | |
229 | def __setitem__(self, index, val): | |
230 | if index == 0: self.x = val | |
231 | elif index == 1: self.y = val | |
232 | else: raise IndexError | |
7e50db3f RD |
233 | def __nonzero__(self): return self.asTuple() != (0,0) |
234 | def __getinitargs__(self): return () | |
235 | def __getstate__(self): return self.asTuple() | |
236 | def __setstate__(self, state): self.Set(*state) | |
211a46cf | 237 | |
8ab979d7 | 238 | class wxPoint(wxPointPtr): |
1d99702e RD |
239 | def __init__(self,*_args,**_kwargs): |
240 | self.this = apply(miscc.new_wxPoint,_args,_kwargs) | |
8ab979d7 RD |
241 | self.thisown = 1 |
242 | ||
243 | ||
244 | ||
245 | ||
246 | class wxRectPtr : | |
247 | def __init__(self,this): | |
248 | self.this = this | |
249 | self.thisown = 0 | |
7e50db3f RD |
250 | def __del__(self, delfunc=miscc.delete_wxRect): |
251 | if self.thisown == 1: | |
252 | try: | |
253 | delfunc(self) | |
254 | except: | |
255 | pass | |
1d99702e RD |
256 | def GetX(self, *_args, **_kwargs): |
257 | val = apply(miscc.wxRect_GetX,(self,) + _args, _kwargs) | |
8ab979d7 | 258 | return val |
1d99702e RD |
259 | def SetX(self, *_args, **_kwargs): |
260 | val = apply(miscc.wxRect_SetX,(self,) + _args, _kwargs) | |
8ab979d7 | 261 | return val |
1d99702e RD |
262 | def GetY(self, *_args, **_kwargs): |
263 | val = apply(miscc.wxRect_GetY,(self,) + _args, _kwargs) | |
8ab979d7 | 264 | return val |
1d99702e RD |
265 | def SetY(self, *_args, **_kwargs): |
266 | val = apply(miscc.wxRect_SetY,(self,) + _args, _kwargs) | |
8ab979d7 | 267 | return val |
1d99702e RD |
268 | def GetWidth(self, *_args, **_kwargs): |
269 | val = apply(miscc.wxRect_GetWidth,(self,) + _args, _kwargs) | |
8ab979d7 | 270 | return val |
1d99702e RD |
271 | def SetWidth(self, *_args, **_kwargs): |
272 | val = apply(miscc.wxRect_SetWidth,(self,) + _args, _kwargs) | |
8ab979d7 | 273 | return val |
1d99702e RD |
274 | def GetHeight(self, *_args, **_kwargs): |
275 | val = apply(miscc.wxRect_GetHeight,(self,) + _args, _kwargs) | |
8ab979d7 | 276 | return val |
1d99702e RD |
277 | def SetHeight(self, *_args, **_kwargs): |
278 | val = apply(miscc.wxRect_SetHeight,(self,) + _args, _kwargs) | |
8ab979d7 | 279 | return val |
1d99702e RD |
280 | def GetPosition(self, *_args, **_kwargs): |
281 | val = apply(miscc.wxRect_GetPosition,(self,) + _args, _kwargs) | |
282 | if val: val = wxPointPtr(val) ; val.thisown = 1 | |
8ab979d7 | 283 | return val |
1d99702e RD |
284 | def GetSize(self, *_args, **_kwargs): |
285 | val = apply(miscc.wxRect_GetSize,(self,) + _args, _kwargs) | |
286 | if val: val = wxSizePtr(val) ; val.thisown = 1 | |
8ab979d7 | 287 | return val |
4c7d2b26 RD |
288 | def SetPosition(self, *_args, **_kwargs): |
289 | val = apply(miscc.wxRect_SetPosition,(self,) + _args, _kwargs) | |
290 | return val | |
291 | def SetSize(self, *_args, **_kwargs): | |
292 | val = apply(miscc.wxRect_SetSize,(self,) + _args, _kwargs) | |
293 | return val | |
1d99702e RD |
294 | def GetLeft(self, *_args, **_kwargs): |
295 | val = apply(miscc.wxRect_GetLeft,(self,) + _args, _kwargs) | |
8ab979d7 | 296 | return val |
1d99702e RD |
297 | def GetTop(self, *_args, **_kwargs): |
298 | val = apply(miscc.wxRect_GetTop,(self,) + _args, _kwargs) | |
8ab979d7 | 299 | return val |
1d99702e RD |
300 | def GetBottom(self, *_args, **_kwargs): |
301 | val = apply(miscc.wxRect_GetBottom,(self,) + _args, _kwargs) | |
8ab979d7 | 302 | return val |
1d99702e RD |
303 | def GetRight(self, *_args, **_kwargs): |
304 | val = apply(miscc.wxRect_GetRight,(self,) + _args, _kwargs) | |
8ab979d7 | 305 | return val |
eb715945 RD |
306 | def SetLeft(self, *_args, **_kwargs): |
307 | val = apply(miscc.wxRect_SetLeft,(self,) + _args, _kwargs) | |
308 | return val | |
309 | def SetRight(self, *_args, **_kwargs): | |
310 | val = apply(miscc.wxRect_SetRight,(self,) + _args, _kwargs) | |
311 | return val | |
312 | def SetTop(self, *_args, **_kwargs): | |
313 | val = apply(miscc.wxRect_SetTop,(self,) + _args, _kwargs) | |
314 | return val | |
315 | def SetBottom(self, *_args, **_kwargs): | |
316 | val = apply(miscc.wxRect_SetBottom,(self,) + _args, _kwargs) | |
317 | return val | |
7e50db3f RD |
318 | def Deflate(self, *_args, **_kwargs): |
319 | val = apply(miscc.wxRect_Deflate,(self,) + _args, _kwargs) | |
320 | return val | |
f6bcfd97 BP |
321 | def Inflate(self, *_args, **_kwargs): |
322 | val = apply(miscc.wxRect_Inflate,(self,) + _args, _kwargs) | |
323 | return val | |
7e50db3f RD |
324 | def InsideXY(self, *_args, **_kwargs): |
325 | val = apply(miscc.wxRect_InsideXY,(self,) + _args, _kwargs) | |
326 | return val | |
f6bcfd97 BP |
327 | def Inside(self, *_args, **_kwargs): |
328 | val = apply(miscc.wxRect_Inside,(self,) + _args, _kwargs) | |
329 | return val | |
7e50db3f RD |
330 | def Intersects(self, *_args, **_kwargs): |
331 | val = apply(miscc.wxRect_Intersects,(self,) + _args, _kwargs) | |
332 | return val | |
333 | def OffsetXY(self, *_args, **_kwargs): | |
334 | val = apply(miscc.wxRect_OffsetXY,(self,) + _args, _kwargs) | |
335 | return val | |
336 | def Offset(self, *_args, **_kwargs): | |
337 | val = apply(miscc.wxRect_Offset,(self,) + _args, _kwargs) | |
338 | return val | |
339 | def Set(self, *_args, **_kwargs): | |
340 | val = apply(miscc.wxRect_Set,(self,) + _args, _kwargs) | |
341 | return val | |
1d99702e RD |
342 | def asTuple(self, *_args, **_kwargs): |
343 | val = apply(miscc.wxRect_asTuple,(self,) + _args, _kwargs) | |
af309447 | 344 | return val |
f6bcfd97 BP |
345 | def __add__(self, *_args, **_kwargs): |
346 | val = apply(miscc.wxRect___add__,(self,) + _args, _kwargs) | |
347 | if val: val = wxRectPtr(val) ; val.thisown = 1 | |
348 | return val | |
7e50db3f RD |
349 | def __eq__(self, *_args, **_kwargs): |
350 | val = apply(miscc.wxRect___eq__,(self,) + _args, _kwargs) | |
351 | return val | |
352 | def __ne__(self, *_args, **_kwargs): | |
353 | val = apply(miscc.wxRect___ne__,(self,) + _args, _kwargs) | |
f6bcfd97 | 354 | return val |
8ab979d7 RD |
355 | def __setattr__(self,name,value): |
356 | if name == "x" : | |
1d99702e | 357 | miscc.wxRect_x_set(self,value) |
8ab979d7 RD |
358 | return |
359 | if name == "y" : | |
1d99702e | 360 | miscc.wxRect_y_set(self,value) |
8ab979d7 RD |
361 | return |
362 | if name == "width" : | |
1d99702e | 363 | miscc.wxRect_width_set(self,value) |
8ab979d7 RD |
364 | return |
365 | if name == "height" : | |
1d99702e | 366 | miscc.wxRect_height_set(self,value) |
8ab979d7 RD |
367 | return |
368 | self.__dict__[name] = value | |
369 | def __getattr__(self,name): | |
370 | if name == "x" : | |
1d99702e | 371 | return miscc.wxRect_x_get(self) |
8ab979d7 | 372 | if name == "y" : |
1d99702e | 373 | return miscc.wxRect_y_get(self) |
8ab979d7 | 374 | if name == "width" : |
1d99702e | 375 | return miscc.wxRect_width_get(self) |
8ab979d7 | 376 | if name == "height" : |
1d99702e | 377 | return miscc.wxRect_height_get(self) |
8ab979d7 RD |
378 | raise AttributeError,name |
379 | def __repr__(self): | |
1d99702e | 380 | return "<C wxRect instance at %s>" % (self.this,) |
9b3d3bc4 | 381 | |
211a46cf | 382 | def __str__(self): return str(self.asTuple()) |
7e50db3f | 383 | def __repr__(self): return 'wxRect'+str(self.asTuple()) |
211a46cf RD |
384 | def __len__(self): return len(self.asTuple()) |
385 | def __getitem__(self, index): return self.asTuple()[index] | |
386 | def __setitem__(self, index, val): | |
387 | if index == 0: self.x = val | |
388 | elif index == 1: self.y = val | |
389 | elif index == 2: self.width = val | |
390 | elif index == 3: self.height = val | |
391 | else: raise IndexError | |
7e50db3f RD |
392 | def __nonzero__(self): return self.asTuple() != (0,0,0,0) |
393 | def __getinitargs__(self): return () | |
394 | def __getstate__(self): return self.asTuple() | |
395 | def __setstate__(self, state): self.Set(*state) | |
211a46cf | 396 | |
9b3d3bc4 RD |
397 | # override the __getattr__ made by SWIG |
398 | def __getattr__(self, name): | |
399 | d = { | |
400 | 'x' : miscc.wxRect_x_get, | |
401 | 'y' : miscc.wxRect_y_get, | |
402 | 'width' : miscc.wxRect_width_get, | |
403 | 'height' : miscc.wxRect_height_get, | |
404 | 'top' : miscc.wxRect_GetTop, | |
405 | 'bottom' : miscc.wxRect_GetBottom, | |
406 | 'left' : miscc.wxRect_GetLeft, | |
407 | 'right' : miscc.wxRect_GetRight, | |
408 | } | |
409 | try: | |
410 | func = d[name] | |
411 | except KeyError: | |
412 | raise AttributeError,name | |
413 | return func(self) | |
414 | ||
415 | # and also the __setattr__ | |
416 | def __setattr__(self, name, value): | |
417 | d = { | |
418 | 'x' : miscc.wxRect_x_set, | |
419 | 'y' : miscc.wxRect_y_set, | |
420 | 'width' : miscc.wxRect_width_set, | |
421 | 'height' : miscc.wxRect_height_set, | |
422 | 'top' : miscc.wxRect_SetTop, | |
423 | 'bottom' : miscc.wxRect_SetBottom, | |
424 | 'left' : miscc.wxRect_SetLeft, | |
425 | 'right' : miscc.wxRect_SetRight, | |
426 | } | |
427 | try: | |
428 | func = d[name] | |
429 | except KeyError: | |
430 | self.__dict__[name] = value | |
431 | return | |
432 | func(self, value) | |
433 | ||
8ab979d7 | 434 | class wxRect(wxRectPtr): |
1d99702e RD |
435 | def __init__(self,*_args,**_kwargs): |
436 | self.this = apply(miscc.new_wxRect,_args,_kwargs) | |
8ab979d7 RD |
437 | self.thisown = 1 |
438 | ||
439 | ||
440 | ||
441 | ||
7e50db3f RD |
442 | class wxPoint2DDoublePtr : |
443 | def __init__(self,this): | |
444 | self.this = this | |
445 | self.thisown = 0 | |
446 | def GetFloor(self, *_args, **_kwargs): | |
447 | val = apply(miscc.wxPoint2DDouble_GetFloor,(self,) + _args, _kwargs) | |
448 | return val | |
449 | def GetRounded(self, *_args, **_kwargs): | |
450 | val = apply(miscc.wxPoint2DDouble_GetRounded,(self,) + _args, _kwargs) | |
451 | return val | |
452 | def GetVectorLength(self, *_args, **_kwargs): | |
453 | val = apply(miscc.wxPoint2DDouble_GetVectorLength,(self,) + _args, _kwargs) | |
454 | return val | |
455 | def GetVectorAngle(self, *_args, **_kwargs): | |
456 | val = apply(miscc.wxPoint2DDouble_GetVectorAngle,(self,) + _args, _kwargs) | |
457 | return val | |
458 | def SetVectorLength(self, *_args, **_kwargs): | |
459 | val = apply(miscc.wxPoint2DDouble_SetVectorLength,(self,) + _args, _kwargs) | |
460 | return val | |
461 | def SetVectorAngle(self, *_args, **_kwargs): | |
462 | val = apply(miscc.wxPoint2DDouble_SetVectorAngle,(self,) + _args, _kwargs) | |
463 | return val | |
464 | def GetDistance(self, *_args, **_kwargs): | |
465 | val = apply(miscc.wxPoint2DDouble_GetDistance,(self,) + _args, _kwargs) | |
466 | return val | |
467 | def GetDistanceSquare(self, *_args, **_kwargs): | |
468 | val = apply(miscc.wxPoint2DDouble_GetDistanceSquare,(self,) + _args, _kwargs) | |
469 | return val | |
470 | def GetDotProduct(self, *_args, **_kwargs): | |
471 | val = apply(miscc.wxPoint2DDouble_GetDotProduct,(self,) + _args, _kwargs) | |
472 | return val | |
473 | def GetCrossProduct(self, *_args, **_kwargs): | |
474 | val = apply(miscc.wxPoint2DDouble_GetCrossProduct,(self,) + _args, _kwargs) | |
475 | return val | |
476 | def Set(self, *_args, **_kwargs): | |
477 | val = apply(miscc.wxPoint2DDouble_Set,(self,) + _args, _kwargs) | |
478 | return val | |
479 | def __neg__(self, *_args, **_kwargs): | |
480 | val = apply(miscc.wxPoint2DDouble___neg__,(self,) + _args, _kwargs) | |
481 | if val: val = wxPoint2DDoublePtr(val) ; val.thisown = 1 | |
482 | return val | |
483 | def __iadd__(self, *_args, **_kwargs): | |
484 | val = apply(miscc.wxPoint2DDouble___iadd__,(self,) + _args, _kwargs) | |
485 | if val: val = wxPoint2DDoublePtr(val) | |
486 | return val | |
487 | def __isub__(self, *_args, **_kwargs): | |
488 | val = apply(miscc.wxPoint2DDouble___isub__,(self,) + _args, _kwargs) | |
489 | if val: val = wxPoint2DDoublePtr(val) | |
490 | return val | |
491 | def __imul__(self, *_args, **_kwargs): | |
492 | val = apply(miscc.wxPoint2DDouble___imul__,(self,) + _args, _kwargs) | |
493 | if val: val = wxPoint2DDoublePtr(val) | |
494 | return val | |
495 | def __idiv__(self, *_args, **_kwargs): | |
496 | val = apply(miscc.wxPoint2DDouble___idiv__,(self,) + _args, _kwargs) | |
497 | if val: val = wxPoint2DDoublePtr(val) | |
498 | return val | |
499 | def __eq__(self, *_args, **_kwargs): | |
500 | val = apply(miscc.wxPoint2DDouble___eq__,(self,) + _args, _kwargs) | |
501 | return val | |
502 | def __ne__(self, *_args, **_kwargs): | |
503 | val = apply(miscc.wxPoint2DDouble___ne__,(self,) + _args, _kwargs) | |
504 | return val | |
505 | def asTuple(self, *_args, **_kwargs): | |
506 | val = apply(miscc.wxPoint2DDouble_asTuple,(self,) + _args, _kwargs) | |
507 | return val | |
508 | def __setattr__(self,name,value): | |
509 | if name == "m_x" : | |
510 | miscc.wxPoint2DDouble_m_x_set(self,value) | |
511 | return | |
512 | if name == "m_y" : | |
513 | miscc.wxPoint2DDouble_m_y_set(self,value) | |
514 | return | |
515 | if name == "x" : | |
516 | miscc.wxPoint2DDouble_x_set(self,value) | |
517 | return | |
518 | if name == "y" : | |
519 | miscc.wxPoint2DDouble_y_set(self,value) | |
520 | return | |
521 | self.__dict__[name] = value | |
522 | def __getattr__(self,name): | |
523 | if name == "m_x" : | |
524 | return miscc.wxPoint2DDouble_m_x_get(self) | |
525 | if name == "m_y" : | |
526 | return miscc.wxPoint2DDouble_m_y_get(self) | |
527 | if name == "x" : | |
528 | return miscc.wxPoint2DDouble_x_get(self) | |
529 | if name == "y" : | |
530 | return miscc.wxPoint2DDouble_y_get(self) | |
531 | raise AttributeError,name | |
532 | def __repr__(self): | |
533 | return "<C wxPoint2DDouble instance at %s>" % (self.this,) | |
534 | ||
535 | def SetPolarCoordinates(self, angle, length): | |
536 | self.SetVectorLength(length) | |
537 | self.SetVectorAngle(angle) | |
538 | def Normalize(self): | |
539 | self.SetVectorLength(1.0) | |
540 | ||
541 | ||
542 | def __str__(self): return str(self.asTuple()) | |
543 | def __repr__(self): return 'wxPoint2DDouble'+str(self.asTuple()) | |
544 | def __len__(self): return len(self.asTuple()) | |
545 | def __getitem__(self, index): return self.asTuple()[index] | |
546 | def __setitem__(self, index, val): | |
547 | if index == 0: self.m_x = val | |
548 | elif index == 1: self.m_yt = val | |
549 | else: raise IndexError | |
550 | def __nonzero__(self): return self.asTuple() != (0.0, 0.0) | |
551 | def __getinitargs__(self): return () | |
552 | def __getstate__(self): return self.asTuple() | |
553 | def __setstate__(self, state): self.Set(*state) | |
554 | ||
555 | class wxPoint2DDouble(wxPoint2DDoublePtr): | |
556 | def __init__(self,*_args,**_kwargs): | |
557 | self.this = apply(miscc.new_wxPoint2DDouble,_args,_kwargs) | |
558 | self.thisown = 1 | |
559 | ||
560 | ||
561 | ||
562 | def wxPoint2DDoubleCopy(*_args,**_kwargs): | |
563 | val = wxPoint2DDoublePtr(apply(miscc.new_wxPoint2DDoubleCopy,_args,_kwargs)) | |
564 | val.thisown = 1 | |
565 | return val | |
566 | ||
567 | def wxPoint2DDoubleFromPoint(*_args,**_kwargs): | |
568 | val = wxPoint2DDoublePtr(apply(miscc.new_wxPoint2DDoubleFromPoint,_args,_kwargs)) | |
569 | val.thisown = 1 | |
570 | return val | |
571 | ||
572 | ||
9416aa89 | 573 | class wxIndividualLayoutConstraintPtr(wxObjectPtr): |
8ab979d7 RD |
574 | def __init__(self,this): |
575 | self.this = this | |
576 | self.thisown = 0 | |
1d99702e RD |
577 | def Above(self, *_args, **_kwargs): |
578 | val = apply(miscc.wxIndividualLayoutConstraint_Above,(self,) + _args, _kwargs) | |
8ab979d7 | 579 | return val |
1d99702e RD |
580 | def Absolute(self, *_args, **_kwargs): |
581 | val = apply(miscc.wxIndividualLayoutConstraint_Absolute,(self,) + _args, _kwargs) | |
8ab979d7 | 582 | return val |
1d99702e RD |
583 | def AsIs(self, *_args, **_kwargs): |
584 | val = apply(miscc.wxIndividualLayoutConstraint_AsIs,(self,) + _args, _kwargs) | |
8ab979d7 | 585 | return val |
1d99702e RD |
586 | def Below(self, *_args, **_kwargs): |
587 | val = apply(miscc.wxIndividualLayoutConstraint_Below,(self,) + _args, _kwargs) | |
8ab979d7 | 588 | return val |
1d99702e RD |
589 | def Unconstrained(self, *_args, **_kwargs): |
590 | val = apply(miscc.wxIndividualLayoutConstraint_Unconstrained,(self,) + _args, _kwargs) | |
8ab979d7 | 591 | return val |
1d99702e RD |
592 | def LeftOf(self, *_args, **_kwargs): |
593 | val = apply(miscc.wxIndividualLayoutConstraint_LeftOf,(self,) + _args, _kwargs) | |
8ab979d7 | 594 | return val |
1d99702e RD |
595 | def PercentOf(self, *_args, **_kwargs): |
596 | val = apply(miscc.wxIndividualLayoutConstraint_PercentOf,(self,) + _args, _kwargs) | |
8ab979d7 | 597 | return val |
1d99702e RD |
598 | def RightOf(self, *_args, **_kwargs): |
599 | val = apply(miscc.wxIndividualLayoutConstraint_RightOf,(self,) + _args, _kwargs) | |
8ab979d7 | 600 | return val |
1d99702e RD |
601 | def SameAs(self, *_args, **_kwargs): |
602 | val = apply(miscc.wxIndividualLayoutConstraint_SameAs,(self,) + _args, _kwargs) | |
8ab979d7 | 603 | return val |
1d99702e RD |
604 | def Set(self, *_args, **_kwargs): |
605 | val = apply(miscc.wxIndividualLayoutConstraint_Set,(self,) + _args, _kwargs) | |
8ab979d7 RD |
606 | return val |
607 | def __repr__(self): | |
1d99702e | 608 | return "<C wxIndividualLayoutConstraint instance at %s>" % (self.this,) |
8ab979d7 RD |
609 | class wxIndividualLayoutConstraint(wxIndividualLayoutConstraintPtr): |
610 | def __init__(self,this): | |
611 | self.this = this | |
612 | ||
613 | ||
614 | ||
615 | ||
9416aa89 | 616 | class wxLayoutConstraintsPtr(wxObjectPtr): |
8ab979d7 RD |
617 | def __init__(self,this): |
618 | self.this = this | |
619 | self.thisown = 0 | |
620 | def __setattr__(self,name,value): | |
621 | if name == "bottom" : | |
1d99702e | 622 | miscc.wxLayoutConstraints_bottom_set(self,value.this) |
8ab979d7 RD |
623 | return |
624 | if name == "centreX" : | |
1d99702e | 625 | miscc.wxLayoutConstraints_centreX_set(self,value.this) |
8ab979d7 RD |
626 | return |
627 | if name == "centreY" : | |
1d99702e | 628 | miscc.wxLayoutConstraints_centreY_set(self,value.this) |
8ab979d7 RD |
629 | return |
630 | if name == "height" : | |
1d99702e | 631 | miscc.wxLayoutConstraints_height_set(self,value.this) |
8ab979d7 RD |
632 | return |
633 | if name == "left" : | |
1d99702e | 634 | miscc.wxLayoutConstraints_left_set(self,value.this) |
8ab979d7 RD |
635 | return |
636 | if name == "right" : | |
1d99702e | 637 | miscc.wxLayoutConstraints_right_set(self,value.this) |
8ab979d7 RD |
638 | return |
639 | if name == "top" : | |
1d99702e | 640 | miscc.wxLayoutConstraints_top_set(self,value.this) |
8ab979d7 RD |
641 | return |
642 | if name == "width" : | |
1d99702e | 643 | miscc.wxLayoutConstraints_width_set(self,value.this) |
8ab979d7 RD |
644 | return |
645 | self.__dict__[name] = value | |
646 | def __getattr__(self,name): | |
647 | if name == "bottom" : | |
1d99702e | 648 | return wxIndividualLayoutConstraintPtr(miscc.wxLayoutConstraints_bottom_get(self)) |
8ab979d7 | 649 | if name == "centreX" : |
1d99702e | 650 | return wxIndividualLayoutConstraintPtr(miscc.wxLayoutConstraints_centreX_get(self)) |
8ab979d7 | 651 | if name == "centreY" : |
1d99702e | 652 | return wxIndividualLayoutConstraintPtr(miscc.wxLayoutConstraints_centreY_get(self)) |
8ab979d7 | 653 | if name == "height" : |
1d99702e | 654 | return wxIndividualLayoutConstraintPtr(miscc.wxLayoutConstraints_height_get(self)) |
8ab979d7 | 655 | if name == "left" : |
1d99702e | 656 | return wxIndividualLayoutConstraintPtr(miscc.wxLayoutConstraints_left_get(self)) |
8ab979d7 | 657 | if name == "right" : |
1d99702e | 658 | return wxIndividualLayoutConstraintPtr(miscc.wxLayoutConstraints_right_get(self)) |
8ab979d7 | 659 | if name == "top" : |
1d99702e | 660 | return wxIndividualLayoutConstraintPtr(miscc.wxLayoutConstraints_top_get(self)) |
8ab979d7 | 661 | if name == "width" : |
1d99702e | 662 | return wxIndividualLayoutConstraintPtr(miscc.wxLayoutConstraints_width_get(self)) |
8ab979d7 RD |
663 | raise AttributeError,name |
664 | def __repr__(self): | |
1d99702e | 665 | return "<C wxLayoutConstraints instance at %s>" % (self.this,) |
8ab979d7 | 666 | class wxLayoutConstraints(wxLayoutConstraintsPtr): |
1d99702e RD |
667 | def __init__(self,*_args,**_kwargs): |
668 | self.this = apply(miscc.new_wxLayoutConstraints,_args,_kwargs) | |
8ab979d7 RD |
669 | self.thisown = 1 |
670 | ||
671 | ||
672 | ||
673 | ||
674 | class wxAcceleratorEntryPtr : | |
675 | def __init__(self,this): | |
676 | self.this = this | |
677 | self.thisown = 0 | |
7e50db3f RD |
678 | def __del__(self, delfunc=miscc.delete_wxAcceleratorEntry): |
679 | if self.thisown == 1: | |
680 | try: | |
681 | delfunc(self) | |
682 | except: | |
683 | pass | |
1d99702e RD |
684 | def Set(self, *_args, **_kwargs): |
685 | val = apply(miscc.wxAcceleratorEntry_Set,(self,) + _args, _kwargs) | |
8ab979d7 | 686 | return val |
1d99702e RD |
687 | def GetFlags(self, *_args, **_kwargs): |
688 | val = apply(miscc.wxAcceleratorEntry_GetFlags,(self,) + _args, _kwargs) | |
8ab979d7 | 689 | return val |
1d99702e RD |
690 | def GetKeyCode(self, *_args, **_kwargs): |
691 | val = apply(miscc.wxAcceleratorEntry_GetKeyCode,(self,) + _args, _kwargs) | |
8ab979d7 | 692 | return val |
1d99702e RD |
693 | def GetCommand(self, *_args, **_kwargs): |
694 | val = apply(miscc.wxAcceleratorEntry_GetCommand,(self,) + _args, _kwargs) | |
8ab979d7 RD |
695 | return val |
696 | def __repr__(self): | |
1d99702e | 697 | return "<C wxAcceleratorEntry instance at %s>" % (self.this,) |
8ab979d7 | 698 | class wxAcceleratorEntry(wxAcceleratorEntryPtr): |
1d99702e RD |
699 | def __init__(self,*_args,**_kwargs): |
700 | self.this = apply(miscc.new_wxAcceleratorEntry,_args,_kwargs) | |
8ab979d7 RD |
701 | self.thisown = 1 |
702 | ||
703 | ||
704 | ||
705 | ||
9416aa89 | 706 | class wxAcceleratorTablePtr(wxObjectPtr): |
8ab979d7 RD |
707 | def __init__(self,this): |
708 | self.this = this | |
709 | self.thisown = 0 | |
7e50db3f RD |
710 | def __del__(self, delfunc=miscc.delete_wxAcceleratorTable): |
711 | if self.thisown == 1: | |
712 | try: | |
713 | delfunc(self) | |
714 | except: | |
715 | pass | |
8ab979d7 | 716 | def __repr__(self): |
1d99702e | 717 | return "<C wxAcceleratorTable instance at %s>" % (self.this,) |
8ab979d7 | 718 | class wxAcceleratorTable(wxAcceleratorTablePtr): |
1d99702e RD |
719 | def __init__(self,*_args,**_kwargs): |
720 | self.this = apply(miscc.new_wxAcceleratorTable,_args,_kwargs) | |
8ab979d7 RD |
721 | self.thisown = 1 |
722 | ||
723 | ||
724 | ||
725 | ||
9416aa89 | 726 | class wxBusyInfoPtr(wxObjectPtr): |
2abc0a0f RD |
727 | def __init__(self,this): |
728 | self.this = this | |
729 | self.thisown = 0 | |
7e50db3f RD |
730 | def __del__(self, delfunc=miscc.delete_wxBusyInfo): |
731 | if self.thisown == 1: | |
732 | try: | |
733 | delfunc(self) | |
734 | except: | |
735 | pass | |
2abc0a0f RD |
736 | def __repr__(self): |
737 | return "<C wxBusyInfo instance at %s>" % (self.this,) | |
738 | class wxBusyInfo(wxBusyInfoPtr): | |
739 | def __init__(self,*_args,**_kwargs): | |
740 | self.this = apply(miscc.new_wxBusyInfo,_args,_kwargs) | |
741 | self.thisown = 1 | |
742 | ||
743 | ||
744 | ||
745 | ||
8ab979d7 RD |
746 | |
747 | ||
748 | #-------------- FUNCTION WRAPPERS ------------------ | |
749 | ||
eb715945 RD |
750 | wxIntersectRect = miscc.wxIntersectRect |
751 | ||
cf694132 RD |
752 | wxNewId = miscc.wxNewId |
753 | ||
754 | wxRegisterId = miscc.wxRegisterId | |
755 | ||
83b18bab RD |
756 | wxGetCurrentId = miscc.wxGetCurrentId |
757 | ||
8ab979d7 RD |
758 | wxBell = miscc.wxBell |
759 | ||
8ab979d7 RD |
760 | wxEndBusyCursor = miscc.wxEndBusyCursor |
761 | ||
8ab979d7 RD |
762 | wxGetElapsedTime = miscc.wxGetElapsedTime |
763 | ||
764 | wxGetFreeMemory = miscc.wxGetFreeMemory | |
765 | ||
766 | wxGetMousePosition = miscc.wxGetMousePosition | |
767 | ||
768 | wxIsBusy = miscc.wxIsBusy | |
769 | ||
770 | wxNow = miscc.wxNow | |
771 | ||
772 | wxShell = miscc.wxShell | |
773 | ||
774 | wxStartTimer = miscc.wxStartTimer | |
775 | ||
776 | wxGetOsVersion = miscc.wxGetOsVersion | |
777 | ||
c368d904 RD |
778 | wxGetOsDescription = miscc.wxGetOsDescription |
779 | ||
b7fc54be RD |
780 | wxShutdown = miscc.wxShutdown |
781 | ||
bb0054cd RD |
782 | wxSleep = miscc.wxSleep |
783 | ||
c368d904 | 784 | wxUsleep = miscc.wxUsleep |
8ab979d7 | 785 | |
c368d904 | 786 | wxYield = miscc.wxYield |
cf694132 | 787 | |
83b18bab RD |
788 | wxYieldIfNeeded = miscc.wxYieldIfNeeded |
789 | ||
bb0054cd RD |
790 | wxEnableTopLevelWindows = miscc.wxEnableTopLevelWindows |
791 | ||
694759cf RD |
792 | wxStripMenuCodes = miscc.wxStripMenuCodes |
793 | ||
c368d904 RD |
794 | wxGetEmailAddress = miscc.wxGetEmailAddress |
795 | ||
796 | wxGetHostName = miscc.wxGetHostName | |
797 | ||
798 | wxGetFullHostName = miscc.wxGetFullHostName | |
799 | ||
800 | wxGetUserId = miscc.wxGetUserId | |
801 | ||
802 | wxGetUserName = miscc.wxGetUserName | |
803 | ||
804 | wxGetHomeDir = miscc.wxGetHomeDir | |
805 | ||
c6c593e8 RD |
806 | wxGetUserHome = miscc.wxGetUserHome |
807 | ||
0815db26 RD |
808 | wxGetProcessId = miscc.wxGetProcessId |
809 | ||
c368d904 RD |
810 | def wxGetAccelFromString(*_args, **_kwargs): |
811 | val = apply(miscc.wxGetAccelFromString,_args,_kwargs) | |
812 | if val: val = wxAcceleratorEntryPtr(val) | |
813 | return val | |
814 | ||
8ab979d7 RD |
815 | |
816 | ||
817 | #-------------- VARIABLE WRAPPERS ------------------ | |
818 | ||
b7fc54be RD |
819 | wxSHUTDOWN_POWEROFF = miscc.wxSHUTDOWN_POWEROFF |
820 | wxSHUTDOWN_REBOOT = miscc.wxSHUTDOWN_REBOOT | |
8ab979d7 RD |
821 | wxLeft = miscc.wxLeft |
822 | wxTop = miscc.wxTop | |
823 | wxRight = miscc.wxRight | |
824 | wxBottom = miscc.wxBottom | |
825 | wxWidth = miscc.wxWidth | |
826 | wxHeight = miscc.wxHeight | |
827 | wxCentre = miscc.wxCentre | |
828 | wxCenter = miscc.wxCenter | |
829 | wxCentreX = miscc.wxCentreX | |
830 | wxCentreY = miscc.wxCentreY | |
831 | wxUnconstrained = miscc.wxUnconstrained | |
832 | wxAsIs = miscc.wxAsIs | |
833 | wxPercentOf = miscc.wxPercentOf | |
834 | wxAbove = miscc.wxAbove | |
835 | wxBelow = miscc.wxBelow | |
836 | wxLeftOf = miscc.wxLeftOf | |
837 | wxRightOf = miscc.wxRightOf | |
838 | wxSameAs = miscc.wxSameAs | |
839 | wxAbsolute = miscc.wxAbsolute | |
f6bcfd97 BP |
840 | cvar = miscc.cvar |
841 | wxNullAcceleratorTable = wxAcceleratorTablePtr(miscc.cvar.wxNullAcceleratorTable) |