]> git.saurik.com Git - wxWidgets.git/blob - wxPython/contrib/xrc/xrc.py
fixes for non interactive execution
[wxWidgets.git] / wxPython / contrib / xrc / xrc.py
1 # This file was created automatically by SWIG.
2 import xrcc
3
4 from misc import *
5
6 from misc2 import *
7
8 from windows import *
9
10 from gdi import *
11
12 from clip_dnd import *
13
14 from events import *
15
16 from streams import *
17
18 from utils import *
19
20 from mdi import *
21
22 from frames import *
23
24 from stattool import *
25
26 from controls import *
27
28 from controls2 import *
29
30 from windows2 import *
31
32 from cmndlgs import *
33
34 from windows3 import *
35
36 from image import *
37
38 from printfw import *
39
40 from sizers import *
41
42 from filesys import *
43
44 def XRCID(str_id):
45 return wxXmlResource_GetXRCID(str_id)
46
47 def XRCCTRL(window, str_id, *ignoreargs):
48 return window.FindWindowById(XRCID(str_id))
49
50 XMLID = XRCID
51 XMLCTRL = XRCCTRL
52
53 class wxXmlResourcePtr(wxObjectPtr):
54 def __init__(self,this):
55 self.this = this
56 self.thisown = 0
57 def __del__(self,xrcc=xrcc):
58 if self.thisown == 1 :
59 xrcc.delete_wxXmlResource(self)
60 def Load(self, *_args, **_kwargs):
61 val = apply(xrcc.wxXmlResource_Load,(self,) + _args, _kwargs)
62 return val
63 def InitAllHandlers(self, *_args, **_kwargs):
64 val = apply(xrcc.wxXmlResource_InitAllHandlers,(self,) + _args, _kwargs)
65 return val
66 def AddHandler(self, *_args, **_kwargs):
67 val = apply(xrcc.wxXmlResource_AddHandler,(self,) + _args, _kwargs)
68 return val
69 def ClearHandlers(self, *_args, **_kwargs):
70 val = apply(xrcc.wxXmlResource_ClearHandlers,(self,) + _args, _kwargs)
71 return val
72 def LoadMenu(self, *_args, **_kwargs):
73 val = apply(xrcc.wxXmlResource_LoadMenu,(self,) + _args, _kwargs)
74 return val
75 def LoadMenuBar(self, *_args, **_kwargs):
76 val = apply(xrcc.wxXmlResource_LoadMenuBar,(self,) + _args, _kwargs)
77 return val
78 def LoadToolBar(self, *_args, **_kwargs):
79 val = apply(xrcc.wxXmlResource_LoadToolBar,(self,) + _args, _kwargs)
80 return val
81 def LoadDialog(self, *_args, **_kwargs):
82 val = apply(xrcc.wxXmlResource_LoadDialog,(self,) + _args, _kwargs)
83 if val: val = wxDialogPtr(val)
84 return val
85 def LoadOnDialog(self, *_args, **_kwargs):
86 val = apply(xrcc.wxXmlResource_LoadOnDialog,(self,) + _args, _kwargs)
87 return val
88 def LoadPanel(self, *_args, **_kwargs):
89 val = apply(xrcc.wxXmlResource_LoadPanel,(self,) + _args, _kwargs)
90 if val: val = wxPanelPtr(val)
91 return val
92 def LoadOnPanel(self, *_args, **_kwargs):
93 val = apply(xrcc.wxXmlResource_LoadOnPanel,(self,) + _args, _kwargs)
94 return val
95 def LoadFrame(self, *_args, **_kwargs):
96 val = apply(xrcc.wxXmlResource_LoadFrame,(self,) + _args, _kwargs)
97 return val
98 def LoadBitmap(self, *_args, **_kwargs):
99 val = apply(xrcc.wxXmlResource_LoadBitmap,(self,) + _args, _kwargs)
100 if val: val = wxBitmapPtr(val) ; val.thisown = 1
101 return val
102 def LoadIcon(self, *_args, **_kwargs):
103 val = apply(xrcc.wxXmlResource_LoadIcon,(self,) + _args, _kwargs)
104 if val: val = wxIconPtr(val) ; val.thisown = 1
105 return val
106 def AttachUnknownControl(self, *_args, **_kwargs):
107 val = apply(xrcc.wxXmlResource_AttachUnknownControl,(self,) + _args, _kwargs)
108 return val
109 def GetVersion(self, *_args, **_kwargs):
110 val = apply(xrcc.wxXmlResource_GetVersion,(self,) + _args, _kwargs)
111 return val
112 def CompareVersion(self, *_args, **_kwargs):
113 val = apply(xrcc.wxXmlResource_CompareVersion,(self,) + _args, _kwargs)
114 return val
115 def __repr__(self):
116 return "<C wxXmlResource instance at %s>" % (self.this,)
117 class wxXmlResource(wxXmlResourcePtr):
118 def __init__(self,*_args,**_kwargs):
119 self.this = apply(xrcc.new_wxXmlResourceEmpty,_args,_kwargs)
120 self.thisown = 1
121
122
123
124 def wxXmlResource(*_args,**_kwargs):
125 val = wxXmlResourcePtr(apply(xrcc.new_wxXmlResource,_args,_kwargs))
126 val.thisown = 1
127 return val
128
129
130
131
132 #-------------- FUNCTION WRAPPERS ------------------
133
134 wxXmlResource_GetXRCID = xrcc.wxXmlResource_GetXRCID
135
136 def wxXmlResource_Get(*_args, **_kwargs):
137 val = apply(xrcc.wxXmlResource_Get,_args,_kwargs)
138 if val: val = wxXmlResourcePtr(val)
139 return val
140
141 def wxXmlResource_Set(*_args, **_kwargs):
142 val = apply(xrcc.wxXmlResource_Set,_args,_kwargs)
143 if val: val = wxXmlResourcePtr(val)
144 return val
145
146
147
148 #-------------- VARIABLE WRAPPERS ------------------
149
150 wxXRC_USE_LOCALE = xrcc.wxXRC_USE_LOCALE
151 wxXRC_NO_SUBCLASSING = xrcc.wxXRC_NO_SUBCLASSING
152
153
154 #-------------- USER INCLUDE -----------------------
155
156
157 # The global was removed in favor of static accessor functions. This is for
158 # backwards compatibility:
159 wxTheXmlResource = wxXmlResource_Get()