updated binding sources to the last version
[Leditor.git] / src / lqt_bind_QLayout.cpp
blobc89eb9ba1ac4381c7dee67a3f0b5cc1f0115d524
1 #include "lqt_bind_QLayout.hpp"
3 int LuaBinder< QLayout >::__LuaWrapCall__indexOf (lua_State *L) {
4 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
5 if (__lua__obj==0) {
6 lua_pushstring(L, "trying to reference deleted pointer");
7 lua_error(L);
8 return 0;
10 QWidget * arg1 = *static_cast<QWidget**>(lqtL_checkudata(L, 2, "QWidget*"));
11 int ret = __lua__obj->QLayout::indexOf(arg1);
12 lua_pushinteger(L, ret);
13 return 1;
15 int LuaBinder< QLayout >::__LuaWrapCall__parentWidget (lua_State *L) {
16 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
17 if (__lua__obj==0) {
18 lua_pushstring(L, "trying to reference deleted pointer");
19 lua_error(L);
20 return 0;
22 QWidget * ret = __lua__obj->QLayout::parentWidget();
23 lqtL_pushudata(L, ret, "QWidget*");
24 return 1;
26 int LuaBinder< QLayout >::__LuaWrapCall__minimumSize (lua_State *L) {
27 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
28 if (__lua__obj==0) {
29 lua_pushstring(L, "trying to reference deleted pointer");
30 lua_error(L);
31 return 0;
33 QSize ret = __lua__obj->QLayout::minimumSize();
34 lqtL_passudata(L, new QSize(ret), "QSize*");
35 return 1;
37 int LuaBinder< QLayout >::__LuaWrapCall__update (lua_State *L) {
38 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
39 if (__lua__obj==0) {
40 lua_pushstring(L, "trying to reference deleted pointer");
41 lua_error(L);
42 return 0;
44 __lua__obj->QLayout::update();
45 return 0;
47 int LuaBinder< QLayout >::__LuaWrapCall__trUtf8__OverloadedVersion__1 (lua_State *L) {
48 const char * arg1 = lua_tostring(L, 1);
49 const char * arg2 = (lua_type(L, 2)==LUA_TSTRING)?lua_tostring(L, 2):static_cast< const char * >(0);
50 QString ret = QLayout::trUtf8(arg1, arg2);
51 lua_pushlstring(L, ret.toAscii().data(), ret.toAscii().size());
52 return 1;
54 int LuaBinder< QLayout >::__LuaWrapCall__trUtf8__OverloadedVersion__2 (lua_State *L) {
55 const char * arg1 = lua_tostring(L, 1);
56 const char * arg2 = lua_tostring(L, 2);
57 int arg3 = lua_tointeger(L, 3);
58 QString ret = QLayout::trUtf8(arg1, arg2, arg3);
59 lua_pushlstring(L, ret.toAscii().data(), ret.toAscii().size());
60 return 1;
62 int LuaBinder< QLayout >::__LuaWrapCall__trUtf8 (lua_State *L) {
63 int score[3];
64 const int premium = 11+lua_gettop(L);
65 score[1] = 0;
66 if ((lua_type(L, 1)==LUA_TSTRING)) {
67 score[1] += premium;
68 } else if (false) {
69 score[1] += premium-1; // table: 0x1468a40;
70 } else {
71 score[1] -= premium*premium;
73 if ((lua_type(L, 2)==LUA_TSTRING)) {
74 score[1] += premium;
75 } else if (true) {
76 score[1] += premium-1; // table: 0x14685a0;
77 } else {
78 score[1] -= premium*premium;
80 score[2] = 0;
81 if ((lua_type(L, 1)==LUA_TSTRING)) {
82 score[2] += premium;
83 } else if (false) {
84 score[2] += premium-1; // table: 0x146a820;
85 } else {
86 score[2] -= premium*premium;
88 if ((lua_type(L, 2)==LUA_TSTRING)) {
89 score[2] += premium;
90 } else if (false) {
91 score[2] += premium-1; // table: 0x1469f50;
92 } else {
93 score[2] -= premium*premium;
95 if (lua_isnumber(L, 3)) {
96 score[2] += premium;
97 } else if (false) {
98 score[2] += premium-1; // table: 0x146acb0;
99 } else {
100 score[2] -= premium*premium;
102 int best = 1;
103 for (int i=1;i<=2;i++) {
104 if (score[best] < score[i]) { best = i; }
106 switch (best) {
107 case 1: return __LuaWrapCall__trUtf8__OverloadedVersion__1(L); break;
108 case 2: return __LuaWrapCall__trUtf8__OverloadedVersion__2(L); break;
110 lua_pushstring(L, "no overload of function __LuaWrapCall__trUtf8 matching arguments");
111 lua_error(L);
112 return 0;
114 int LuaBinder< QLayout >::__LuaWrapCall__totalMaximumSize (lua_State *L) {
115 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
116 if (__lua__obj==0) {
117 lua_pushstring(L, "trying to reference deleted pointer");
118 lua_error(L);
119 return 0;
121 QSize ret = __lua__obj->QLayout::totalMaximumSize();
122 lqtL_passudata(L, new QSize(ret), "QSize*");
123 return 1;
125 int LuaBinder< QLayout >::__LuaWrapCall__tr__OverloadedVersion__1 (lua_State *L) {
126 const char * arg1 = lua_tostring(L, 1);
127 const char * arg2 = (lua_type(L, 2)==LUA_TSTRING)?lua_tostring(L, 2):static_cast< const char * >(0);
128 QString ret = QLayout::tr(arg1, arg2);
129 lua_pushlstring(L, ret.toAscii().data(), ret.toAscii().size());
130 return 1;
132 int LuaBinder< QLayout >::__LuaWrapCall__tr__OverloadedVersion__2 (lua_State *L) {
133 const char * arg1 = lua_tostring(L, 1);
134 const char * arg2 = lua_tostring(L, 2);
135 int arg3 = lua_tointeger(L, 3);
136 QString ret = QLayout::tr(arg1, arg2, arg3);
137 lua_pushlstring(L, ret.toAscii().data(), ret.toAscii().size());
138 return 1;
140 int LuaBinder< QLayout >::__LuaWrapCall__tr (lua_State *L) {
141 int score[3];
142 const int premium = 11+lua_gettop(L);
143 score[1] = 0;
144 if ((lua_type(L, 1)==LUA_TSTRING)) {
145 score[1] += premium;
146 } else if (false) {
147 score[1] += premium-1; // table: 0x1467d00;
148 } else {
149 score[1] -= premium*premium;
151 if ((lua_type(L, 2)==LUA_TSTRING)) {
152 score[1] += premium;
153 } else if (true) {
154 score[1] += premium-1; // table: 0x1467a70;
155 } else {
156 score[1] -= premium*premium;
158 score[2] = 0;
159 if ((lua_type(L, 1)==LUA_TSTRING)) {
160 score[2] += premium;
161 } else if (false) {
162 score[2] += premium-1; // table: 0x1469710;
163 } else {
164 score[2] -= premium*premium;
166 if ((lua_type(L, 2)==LUA_TSTRING)) {
167 score[2] += premium;
168 } else if (false) {
169 score[2] += premium-1; // table: 0x1469c00;
170 } else {
171 score[2] -= premium*premium;
173 if (lua_isnumber(L, 3)) {
174 score[2] += premium;
175 } else if (false) {
176 score[2] += premium-1; // table: 0x1469fb0;
177 } else {
178 score[2] -= premium*premium;
180 int best = 1;
181 for (int i=1;i<=2;i++) {
182 if (score[best] < score[i]) { best = i; }
184 switch (best) {
185 case 1: return __LuaWrapCall__tr__OverloadedVersion__1(L); break;
186 case 2: return __LuaWrapCall__tr__OverloadedVersion__2(L); break;
188 lua_pushstring(L, "no overload of function __LuaWrapCall__tr matching arguments");
189 lua_error(L);
190 return 0;
192 int LuaBinder< QLayout >::__LuaWrapCall__isEmpty (lua_State *L) {
193 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
194 if (__lua__obj==0) {
195 lua_pushstring(L, "trying to reference deleted pointer");
196 lua_error(L);
197 return 0;
199 bool ret = __lua__obj->QLayout::isEmpty();
200 lua_pushboolean(L, ret);
201 return 1;
203 int LuaBinder< QLayout >::__LuaWrapCall__setAlignment__OverloadedVersion__1 (lua_State *L) {
204 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
205 if (__lua__obj==0) {
206 lua_pushstring(L, "trying to reference deleted pointer");
207 lua_error(L);
208 return 0;
210 QWidget * arg1 = *static_cast<QWidget**>(lqtL_checkudata(L, 2, "QWidget*"));
211 QFlags<Qt::AlignmentFlag> arg2 = **static_cast<QFlags<Qt::AlignmentFlag>**>(lqtL_checkudata(L, 3, "QFlags<Qt::AlignmentFlag>*"));
212 bool ret = __lua__obj->QLayout::setAlignment(arg1, arg2);
213 lua_pushboolean(L, ret);
214 return 1;
216 int LuaBinder< QLayout >::__LuaWrapCall__setAlignment__OverloadedVersion__2 (lua_State *L) {
217 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
218 if (__lua__obj==0) {
219 lua_pushstring(L, "trying to reference deleted pointer");
220 lua_error(L);
221 return 0;
223 QLayout * arg1 = *static_cast<QLayout**>(lqtL_checkudata(L, 2, "QLayout*"));
224 QFlags<Qt::AlignmentFlag> arg2 = **static_cast<QFlags<Qt::AlignmentFlag>**>(lqtL_checkudata(L, 3, "QFlags<Qt::AlignmentFlag>*"));
225 bool ret = __lua__obj->QLayout::setAlignment(arg1, arg2);
226 lua_pushboolean(L, ret);
227 return 1;
229 int LuaBinder< QLayout >::__LuaWrapCall__setAlignment (lua_State *L) {
230 int score[3];
231 const int premium = 11+lua_gettop(L);
232 score[1] = 0;
233 score[1] += lqtL_testudata(L, 1, "QLayout*")?premium:-premium*premium;
234 if (lqtL_testudata(L, 2, "QWidget*")) {
235 score[1] += premium;
236 } else if (false) {
237 score[1] += premium-1; // table: 0x1474330;
238 } else {
239 score[1] -= premium*premium;
241 if (lqtL_testudata(L, 3, "QFlags<Qt::AlignmentFlag>*")) {
242 score[1] += premium;
243 } else if (false) {
244 score[1] += premium-1; // table: 0x1474040;
245 } else {
246 score[1] -= premium*premium;
248 score[2] = 0;
249 score[2] += lqtL_testudata(L, 1, "QLayout*")?premium:-premium*premium;
250 if (lqtL_testudata(L, 2, "QLayout*")) {
251 score[2] += premium;
252 } else if (false) {
253 score[2] += premium-1; // table: 0x1475200;
254 } else {
255 score[2] -= premium*premium;
257 if (lqtL_testudata(L, 3, "QFlags<Qt::AlignmentFlag>*")) {
258 score[2] += premium;
259 } else if (false) {
260 score[2] += premium-1; // table: 0x1474c60;
261 } else {
262 score[2] -= premium*premium;
264 int best = 1;
265 for (int i=1;i<=2;i++) {
266 if (score[best] < score[i]) { best = i; }
268 switch (best) {
269 case 1: return __LuaWrapCall__setAlignment__OverloadedVersion__1(L); break;
270 case 2: return __LuaWrapCall__setAlignment__OverloadedVersion__2(L); break;
272 lua_pushstring(L, "no overload of function __LuaWrapCall__setAlignment matching arguments");
273 lua_error(L);
274 return 0;
276 int LuaBinder< QLayout >::__LuaWrapCall__expandingDirections (lua_State *L) {
277 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
278 if (__lua__obj==0) {
279 lua_pushstring(L, "trying to reference deleted pointer");
280 lua_error(L);
281 return 0;
283 QFlags<Qt::Orientation> ret = __lua__obj->QLayout::expandingDirections();
284 lqtL_passudata(L, new QFlags<Qt::Orientation>(ret), "QFlags<Qt::Orientation>*");
285 return 1;
287 int LuaBinder< QLayout >::__LuaWrapCall__addWidget (lua_State *L) {
288 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
289 if (__lua__obj==0) {
290 lua_pushstring(L, "trying to reference deleted pointer");
291 lua_error(L);
292 return 0;
294 QWidget * arg1 = *static_cast<QWidget**>(lqtL_checkudata(L, 2, "QWidget*"));
295 __lua__obj->QLayout::addWidget(arg1);
296 return 0;
298 int LuaBinder< QLayout >::__LuaWrapCall__removeWidget (lua_State *L) {
299 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
300 if (__lua__obj==0) {
301 lua_pushstring(L, "trying to reference deleted pointer");
302 lua_error(L);
303 return 0;
305 QWidget * arg1 = *static_cast<QWidget**>(lqtL_checkudata(L, 2, "QWidget*"));
306 __lua__obj->QLayout::removeWidget(arg1);
307 return 0;
309 int LuaBinder< QLayout >::__LuaWrapCall__activate (lua_State *L) {
310 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
311 if (__lua__obj==0) {
312 lua_pushstring(L, "trying to reference deleted pointer");
313 lua_error(L);
314 return 0;
316 bool ret = __lua__obj->QLayout::activate();
317 lua_pushboolean(L, ret);
318 return 1;
320 int LuaBinder< QLayout >::__LuaWrapCall__setMargin (lua_State *L) {
321 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
322 if (__lua__obj==0) {
323 lua_pushstring(L, "trying to reference deleted pointer");
324 lua_error(L);
325 return 0;
327 int arg1 = lua_tointeger(L, 2);
328 __lua__obj->QLayout::setMargin(arg1);
329 return 0;
331 int LuaBinder< QLayout >::__LuaWrapCall__delete (lua_State *L) {
332 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
333 if (__lua__obj==0) {
334 lua_pushstring(L, "trying to reference deleted pointer");
335 lua_error(L);
336 return 0;
338 delete __lua__obj;
339 __lua__obj = 0;
340 return 0;
342 int LuaBinder< QLayout >::__LuaWrapCall__totalMinimumSize (lua_State *L) {
343 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
344 if (__lua__obj==0) {
345 lua_pushstring(L, "trying to reference deleted pointer");
346 lua_error(L);
347 return 0;
349 QSize ret = __lua__obj->QLayout::totalMinimumSize();
350 lqtL_passudata(L, new QSize(ret), "QSize*");
351 return 1;
353 int LuaBinder< QLayout >::__LuaWrapCall__layout (lua_State *L) {
354 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
355 if (__lua__obj==0) {
356 lua_pushstring(L, "trying to reference deleted pointer");
357 lua_error(L);
358 return 0;
360 QLayout * ret = __lua__obj->QLayout::layout();
361 lqtL_pushudata(L, ret, "QLayout*");
362 return 1;
364 int LuaBinder< QLayout >::__LuaWrapCall__margin (lua_State *L) {
365 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
366 if (__lua__obj==0) {
367 lua_pushstring(L, "trying to reference deleted pointer");
368 lua_error(L);
369 return 0;
371 int ret = __lua__obj->QLayout::margin();
372 lua_pushinteger(L, ret);
373 return 1;
375 int LuaBinder< QLayout >::__LuaWrapCall__menuBar (lua_State *L) {
376 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
377 if (__lua__obj==0) {
378 lua_pushstring(L, "trying to reference deleted pointer");
379 lua_error(L);
380 return 0;
382 QWidget * ret = __lua__obj->QLayout::menuBar();
383 lqtL_pushudata(L, ret, "QWidget*");
384 return 1;
386 int LuaBinder< QLayout >::__LuaWrapCall__geometry (lua_State *L) {
387 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
388 if (__lua__obj==0) {
389 lua_pushstring(L, "trying to reference deleted pointer");
390 lua_error(L);
391 return 0;
393 QRect ret = __lua__obj->QLayout::geometry();
394 lqtL_passudata(L, new QRect(ret), "QRect*");
395 return 1;
397 int LuaBinder< QLayout >::__LuaWrapCall__spacing (lua_State *L) {
398 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
399 if (__lua__obj==0) {
400 lua_pushstring(L, "trying to reference deleted pointer");
401 lua_error(L);
402 return 0;
404 int ret = __lua__obj->QLayout::spacing();
405 lua_pushinteger(L, ret);
406 return 1;
408 int LuaBinder< QLayout >::__LuaWrapCall__sizeConstraint (lua_State *L) {
409 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
410 if (__lua__obj==0) {
411 lua_pushstring(L, "trying to reference deleted pointer");
412 lua_error(L);
413 return 0;
415 QLayout::SizeConstraint ret = __lua__obj->QLayout::sizeConstraint();
416 lqtL_pushenum(L, ret, "QLayout::SizeConstraint");
417 return 1;
419 int LuaBinder< QLayout >::__LuaWrapCall__setContentsMargins (lua_State *L) {
420 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
421 if (__lua__obj==0) {
422 lua_pushstring(L, "trying to reference deleted pointer");
423 lua_error(L);
424 return 0;
426 int arg1 = lua_tointeger(L, 2);
427 int arg2 = lua_tointeger(L, 3);
428 int arg3 = lua_tointeger(L, 4);
429 int arg4 = lua_tointeger(L, 5);
430 __lua__obj->QLayout::setContentsMargins(arg1, arg2, arg3, arg4);
431 return 0;
433 int LuaBinder< QLayout >::__LuaWrapCall__metaObject (lua_State *L) {
434 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
435 if (__lua__obj==0) {
436 lua_pushstring(L, "trying to reference deleted pointer");
437 lua_error(L);
438 return 0;
440 const QMetaObject * ret = __lua__obj->QLayout::metaObject();
441 lqtL_pushudata(L, ret, "QMetaObject*");
442 return 1;
444 int LuaBinder< QLayout >::__LuaWrapCall__new__OverloadedVersion__1 (lua_State *L) {
445 QWidget * arg1 = *static_cast<QWidget**>(lqtL_checkudata(L, 1, "QWidget*"));
446 QLayout * ret = new LuaBinder< QLayout >(L, arg1);
447 lqtL_passudata(L, ret, "QLayout*");
448 return 1;
450 int LuaBinder< QLayout >::__LuaWrapCall__new__OverloadedVersion__2 (lua_State *L) {
451 QLayout * ret = new LuaBinder< QLayout >(L);
452 lqtL_passudata(L, ret, "QLayout*");
453 return 1;
455 int LuaBinder< QLayout >::__LuaWrapCall__new (lua_State *L) {
456 int score[3];
457 const int premium = 11+lua_gettop(L);
458 score[1] = 0;
459 if (lqtL_testudata(L, 1, "QWidget*")) {
460 score[1] += premium;
461 } else if (false) {
462 score[1] += premium-1; // table: 0x146d6c0;
463 } else {
464 score[1] -= premium*premium;
466 score[2] = 0;
467 int best = 1;
468 for (int i=1;i<=2;i++) {
469 if (score[best] < score[i]) { best = i; }
471 switch (best) {
472 case 1: return __LuaWrapCall__new__OverloadedVersion__1(L); break;
473 case 2: return __LuaWrapCall__new__OverloadedVersion__2(L); break;
475 lua_pushstring(L, "no overload of function __LuaWrapCall__new matching arguments");
476 lua_error(L);
477 return 0;
479 int LuaBinder< QLayout >::__LuaWrapCall__contentsRect (lua_State *L) {
480 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
481 if (__lua__obj==0) {
482 lua_pushstring(L, "trying to reference deleted pointer");
483 lua_error(L);
484 return 0;
486 QRect ret = __lua__obj->QLayout::contentsRect();
487 lqtL_passudata(L, new QRect(ret), "QRect*");
488 return 1;
490 int LuaBinder< QLayout >::__LuaWrapCall__getContentsMargins (lua_State *L) {
491 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
492 if (__lua__obj==0) {
493 lua_pushstring(L, "trying to reference deleted pointer");
494 lua_error(L);
495 return 0;
497 int * arg1 = static_cast<int *>(lua_touserdata(L, 2));
498 int * arg2 = static_cast<int *>(lua_touserdata(L, 3));
499 int * arg3 = static_cast<int *>(lua_touserdata(L, 4));
500 int * arg4 = static_cast<int *>(lua_touserdata(L, 5));
501 __lua__obj->QLayout::getContentsMargins(arg1, arg2, arg3, arg4);
502 return 0;
504 int LuaBinder< QLayout >::__LuaWrapCall__invalidate (lua_State *L) {
505 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
506 if (__lua__obj==0) {
507 lua_pushstring(L, "trying to reference deleted pointer");
508 lua_error(L);
509 return 0;
511 __lua__obj->QLayout::invalidate();
512 return 0;
514 int LuaBinder< QLayout >::__LuaWrapCall__maximumSize (lua_State *L) {
515 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
516 if (__lua__obj==0) {
517 lua_pushstring(L, "trying to reference deleted pointer");
518 lua_error(L);
519 return 0;
521 QSize ret = __lua__obj->QLayout::maximumSize();
522 lqtL_passudata(L, new QSize(ret), "QSize*");
523 return 1;
525 int LuaBinder< QLayout >::__LuaWrapCall__setMenuBar (lua_State *L) {
526 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
527 if (__lua__obj==0) {
528 lua_pushstring(L, "trying to reference deleted pointer");
529 lua_error(L);
530 return 0;
532 QWidget * arg1 = *static_cast<QWidget**>(lqtL_checkudata(L, 2, "QWidget*"));
533 __lua__obj->QLayout::setMenuBar(arg1);
534 return 0;
536 int LuaBinder< QLayout >::__LuaWrapCall__totalSizeHint (lua_State *L) {
537 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
538 if (__lua__obj==0) {
539 lua_pushstring(L, "trying to reference deleted pointer");
540 lua_error(L);
541 return 0;
543 QSize ret = __lua__obj->QLayout::totalSizeHint();
544 lqtL_passudata(L, new QSize(ret), "QSize*");
545 return 1;
547 int LuaBinder< QLayout >::__LuaWrapCall__setSpacing (lua_State *L) {
548 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
549 if (__lua__obj==0) {
550 lua_pushstring(L, "trying to reference deleted pointer");
551 lua_error(L);
552 return 0;
554 int arg1 = lua_tointeger(L, 2);
555 __lua__obj->QLayout::setSpacing(arg1);
556 return 0;
558 int LuaBinder< QLayout >::__LuaWrapCall__closestAcceptableSize (lua_State *L) {
559 const QWidget * arg1 = *static_cast<QWidget**>(lqtL_checkudata(L, 1, "QWidget*"));
560 const QSize& arg2 = **static_cast<QSize**>(lqtL_checkudata(L, 2, "QSize*"));
561 QSize ret = QLayout::closestAcceptableSize(arg1, arg2);
562 lqtL_passudata(L, new QSize(ret), "QSize*");
563 return 1;
565 int LuaBinder< QLayout >::__LuaWrapCall__setSizeConstraint (lua_State *L) {
566 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
567 if (__lua__obj==0) {
568 lua_pushstring(L, "trying to reference deleted pointer");
569 lua_error(L);
570 return 0;
572 QLayout::SizeConstraint arg1 = static_cast<QLayout::SizeConstraint>(lqtL_toenum(L, 2, "QLayout::SizeConstraint"));
573 __lua__obj->QLayout::setSizeConstraint(arg1);
574 return 0;
576 int LuaBinder< QLayout >::__LuaWrapCall__isEnabled (lua_State *L) {
577 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
578 if (__lua__obj==0) {
579 lua_pushstring(L, "trying to reference deleted pointer");
580 lua_error(L);
581 return 0;
583 bool ret = __lua__obj->QLayout::isEnabled();
584 lua_pushboolean(L, ret);
585 return 1;
587 int LuaBinder< QLayout >::__LuaWrapCall__removeItem (lua_State *L) {
588 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
589 if (__lua__obj==0) {
590 lua_pushstring(L, "trying to reference deleted pointer");
591 lua_error(L);
592 return 0;
594 QLayoutItem * arg1 = *static_cast<QLayoutItem**>(lqtL_checkudata(L, 2, "QLayoutItem*"));
595 __lua__obj->QLayout::removeItem(arg1);
596 return 0;
598 int LuaBinder< QLayout >::__LuaWrapCall__setEnabled (lua_State *L) {
599 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
600 if (__lua__obj==0) {
601 lua_pushstring(L, "trying to reference deleted pointer");
602 lua_error(L);
603 return 0;
605 bool arg1 = (bool)lua_toboolean(L, 2);
606 __lua__obj->QLayout::setEnabled(arg1);
607 return 0;
609 int LuaBinder< QLayout >::__LuaWrapCall__totalHeightForWidth (lua_State *L) {
610 QLayout *& __lua__obj = *static_cast<QLayout**>(lqtL_checkudata(L, 1, "QLayout*"));
611 if (__lua__obj==0) {
612 lua_pushstring(L, "trying to reference deleted pointer");
613 lua_error(L);
614 return 0;
616 int arg1 = lua_tointeger(L, 2);
617 int ret = __lua__obj->QLayout::totalHeightForWidth(arg1);
618 lua_pushinteger(L, ret);
619 return 1;
621 QLayout * LuaBinder< QLayout >::layout () {
622 bool absorbed = false;
623 int oldtop = lua_gettop(L);
624 lqtL_pushudata(L, this, "QLayout*");
625 if (lua_getmetatable(L, -1)) {
626 lua_getfield(L, -1, "layout");
627 lua_remove(L, -2);
628 } else {
629 lua_pushnil(L);
631 lua_insert(L, -2);
632 if (lua_isfunction(L, -0-2)) {
633 lua_pcall(L, 0+1, 2, 0);
634 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
635 lua_pop(L, 1);
637 if (!absorbed) {
638 lua_settop(L, oldtop);
639 return this->QLayout::layout();
641 QLayout * ret = *static_cast<QLayout**>(lqtL_checkudata(L, -1, "QLayout*"));
642 lua_settop(L, oldtop);
643 return ret;
645 QLayoutItem * LuaBinder< QLayout >::takeAt (int arg1) {
646 bool absorbed = false;
647 int oldtop = lua_gettop(L);
648 lqtL_pushudata(L, this, "QLayout*");
649 if (lua_getmetatable(L, -1)) {
650 lua_getfield(L, -1, "takeAt");
651 lua_remove(L, -2);
652 } else {
653 lua_pushnil(L);
655 lua_insert(L, -2);
656 lua_pushinteger(L, arg1);
657 if (lua_isfunction(L, -1-2)) {
658 lua_pcall(L, 1+1, 2, 0);
659 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
660 lua_pop(L, 1);
662 if (!absorbed) {
663 lua_settop(L, oldtop);
665 QLayoutItem * ret = *static_cast<QLayoutItem**>(lqtL_checkudata(L, -1, "QLayoutItem*"));
666 lua_settop(L, oldtop);
667 return ret;
669 const QMetaObject * LuaBinder< QLayout >::metaObject () const {
670 bool absorbed = false;
671 int oldtop = lua_gettop(L);
672 lqtL_pushudata(L, this, "QLayout*");
673 if (lua_getmetatable(L, -1)) {
674 lua_getfield(L, -1, "metaObject");
675 lua_remove(L, -2);
676 } else {
677 lua_pushnil(L);
679 lua_insert(L, -2);
680 if (lua_isfunction(L, -0-2)) {
681 lua_pcall(L, 0+1, 2, 0);
682 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
683 lua_pop(L, 1);
685 if (!absorbed) {
686 lua_settop(L, oldtop);
687 return this->QLayout::metaObject();
689 const QMetaObject * ret = *static_cast<QMetaObject**>(lqtL_checkudata(L, -1, "QMetaObject*"));
690 lua_settop(L, oldtop);
691 return ret;
693 QLayoutItem * LuaBinder< QLayout >::itemAt (int arg1) const {
694 bool absorbed = false;
695 int oldtop = lua_gettop(L);
696 lqtL_pushudata(L, this, "QLayout*");
697 if (lua_getmetatable(L, -1)) {
698 lua_getfield(L, -1, "itemAt");
699 lua_remove(L, -2);
700 } else {
701 lua_pushnil(L);
703 lua_insert(L, -2);
704 lua_pushinteger(L, arg1);
705 if (lua_isfunction(L, -1-2)) {
706 lua_pcall(L, 1+1, 2, 0);
707 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
708 lua_pop(L, 1);
710 if (!absorbed) {
711 lua_settop(L, oldtop);
713 QLayoutItem * ret = *static_cast<QLayoutItem**>(lqtL_checkudata(L, -1, "QLayoutItem*"));
714 lua_settop(L, oldtop);
715 return ret;
717 int LuaBinder< QLayout >::heightForWidth (int arg1) const {
718 bool absorbed = false;
719 int oldtop = lua_gettop(L);
720 lqtL_pushudata(L, this, "QLayout*");
721 if (lua_getmetatable(L, -1)) {
722 lua_getfield(L, -1, "heightForWidth");
723 lua_remove(L, -2);
724 } else {
725 lua_pushnil(L);
727 lua_insert(L, -2);
728 lua_pushinteger(L, arg1);
729 if (lua_isfunction(L, -1-2)) {
730 lua_pcall(L, 1+1, 2, 0);
731 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
732 lua_pop(L, 1);
734 if (!absorbed) {
735 lua_settop(L, oldtop);
736 return this->QLayoutItem::heightForWidth(arg1);
738 int ret = lua_tointeger(L, -1);
739 lua_settop(L, oldtop);
740 return ret;
742 int LuaBinder< QLayout >::minimumHeightForWidth (int arg1) const {
743 bool absorbed = false;
744 int oldtop = lua_gettop(L);
745 lqtL_pushudata(L, this, "QLayout*");
746 if (lua_getmetatable(L, -1)) {
747 lua_getfield(L, -1, "minimumHeightForWidth");
748 lua_remove(L, -2);
749 } else {
750 lua_pushnil(L);
752 lua_insert(L, -2);
753 lua_pushinteger(L, arg1);
754 if (lua_isfunction(L, -1-2)) {
755 lua_pcall(L, 1+1, 2, 0);
756 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
757 lua_pop(L, 1);
759 if (!absorbed) {
760 lua_settop(L, oldtop);
761 return this->QLayoutItem::minimumHeightForWidth(arg1);
763 int ret = lua_tointeger(L, -1);
764 lua_settop(L, oldtop);
765 return ret;
767 void LuaBinder< QLayout >::invalidate () {
768 bool absorbed = false;
769 int oldtop = lua_gettop(L);
770 lqtL_pushudata(L, this, "QLayout*");
771 if (lua_getmetatable(L, -1)) {
772 lua_getfield(L, -1, "invalidate");
773 lua_remove(L, -2);
774 } else {
775 lua_pushnil(L);
777 lua_insert(L, -2);
778 if (lua_isfunction(L, -0-2)) {
779 lua_pcall(L, 0+1, 2, 0);
780 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
781 lua_pop(L, 1);
783 if (!absorbed) {
784 lua_settop(L, oldtop);
785 this->QLayout::invalidate();
787 lua_settop(L, oldtop);
789 QWidget * LuaBinder< QLayout >::widget () {
790 bool absorbed = false;
791 int oldtop = lua_gettop(L);
792 lqtL_pushudata(L, this, "QLayout*");
793 if (lua_getmetatable(L, -1)) {
794 lua_getfield(L, -1, "widget");
795 lua_remove(L, -2);
796 } else {
797 lua_pushnil(L);
799 lua_insert(L, -2);
800 if (lua_isfunction(L, -0-2)) {
801 lua_pcall(L, 0+1, 2, 0);
802 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
803 lua_pop(L, 1);
805 if (!absorbed) {
806 lua_settop(L, oldtop);
807 return this->QLayoutItem::widget();
809 QWidget * ret = *static_cast<QWidget**>(lqtL_checkudata(L, -1, "QWidget*"));
810 lua_settop(L, oldtop);
811 return ret;
813 bool LuaBinder< QLayout >::hasHeightForWidth () const {
814 bool absorbed = false;
815 int oldtop = lua_gettop(L);
816 lqtL_pushudata(L, this, "QLayout*");
817 if (lua_getmetatable(L, -1)) {
818 lua_getfield(L, -1, "hasHeightForWidth");
819 lua_remove(L, -2);
820 } else {
821 lua_pushnil(L);
823 lua_insert(L, -2);
824 if (lua_isfunction(L, -0-2)) {
825 lua_pcall(L, 0+1, 2, 0);
826 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
827 lua_pop(L, 1);
829 if (!absorbed) {
830 lua_settop(L, oldtop);
831 return this->QLayoutItem::hasHeightForWidth();
833 bool ret = (bool)lua_toboolean(L, -1);
834 lua_settop(L, oldtop);
835 return ret;
837 void LuaBinder< QLayout >::childEvent (QChildEvent * arg1) {
838 bool absorbed = false;
839 int oldtop = lua_gettop(L);
840 lqtL_pushudata(L, this, "QLayout*");
841 if (lua_getmetatable(L, -1)) {
842 lua_getfield(L, -1, "childEvent");
843 lua_remove(L, -2);
844 } else {
845 lua_pushnil(L);
847 lua_insert(L, -2);
848 lqtL_pushudata(L, arg1, "QChildEvent*");
849 if (lua_isfunction(L, -1-2)) {
850 lua_pcall(L, 1+1, 2, 0);
851 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
852 lua_pop(L, 1);
854 if (!absorbed) {
855 lua_settop(L, oldtop);
856 this->QLayout::childEvent(arg1);
858 lua_settop(L, oldtop);
860 QSize LuaBinder< QLayout >::maximumSize () const {
861 bool absorbed = false;
862 int oldtop = lua_gettop(L);
863 lqtL_pushudata(L, this, "QLayout*");
864 if (lua_getmetatable(L, -1)) {
865 lua_getfield(L, -1, "maximumSize");
866 lua_remove(L, -2);
867 } else {
868 lua_pushnil(L);
870 lua_insert(L, -2);
871 if (lua_isfunction(L, -0-2)) {
872 lua_pcall(L, 0+1, 2, 0);
873 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
874 lua_pop(L, 1);
876 if (!absorbed) {
877 lua_settop(L, oldtop);
878 return this->QLayout::maximumSize();
880 QSize ret = **static_cast<QSize**>(lqtL_checkudata(L, -1, "QSize*"));
881 lua_settop(L, oldtop);
882 return ret;
884 int LuaBinder< QLayout >::indexOf (QWidget * arg1) const {
885 bool absorbed = false;
886 int oldtop = lua_gettop(L);
887 lqtL_pushudata(L, this, "QLayout*");
888 if (lua_getmetatable(L, -1)) {
889 lua_getfield(L, -1, "indexOf");
890 lua_remove(L, -2);
891 } else {
892 lua_pushnil(L);
894 lua_insert(L, -2);
895 lqtL_pushudata(L, arg1, "QWidget*");
896 if (lua_isfunction(L, -1-2)) {
897 lua_pcall(L, 1+1, 2, 0);
898 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
899 lua_pop(L, 1);
901 if (!absorbed) {
902 lua_settop(L, oldtop);
903 return this->QLayout::indexOf(arg1);
905 int ret = lua_tointeger(L, -1);
906 lua_settop(L, oldtop);
907 return ret;
909 void LuaBinder< QLayout >::addItem (QLayoutItem * arg1) {
910 bool absorbed = false;
911 int oldtop = lua_gettop(L);
912 lqtL_pushudata(L, this, "QLayout*");
913 if (lua_getmetatable(L, -1)) {
914 lua_getfield(L, -1, "addItem");
915 lua_remove(L, -2);
916 } else {
917 lua_pushnil(L);
919 lua_insert(L, -2);
920 lqtL_pushudata(L, arg1, "QLayoutItem*");
921 if (lua_isfunction(L, -1-2)) {
922 lua_pcall(L, 1+1, 2, 0);
923 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
924 lua_pop(L, 1);
926 if (!absorbed) {
927 lua_settop(L, oldtop);
929 lua_settop(L, oldtop);
931 bool LuaBinder< QLayout >::eventFilter (QObject * arg1, QEvent * arg2) {
932 bool absorbed = false;
933 int oldtop = lua_gettop(L);
934 lqtL_pushudata(L, this, "QLayout*");
935 if (lua_getmetatable(L, -1)) {
936 lua_getfield(L, -1, "eventFilter");
937 lua_remove(L, -2);
938 } else {
939 lua_pushnil(L);
941 lua_insert(L, -2);
942 lqtL_pushudata(L, arg1, "QObject*");
943 lqtL_pushudata(L, arg2, "QEvent*");
944 if (lua_isfunction(L, -2-2)) {
945 lua_pcall(L, 2+1, 2, 0);
946 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
947 lua_pop(L, 1);
949 if (!absorbed) {
950 lua_settop(L, oldtop);
951 return this->QObject::eventFilter(arg1, arg2);
953 bool ret = (bool)lua_toboolean(L, -1);
954 lua_settop(L, oldtop);
955 return ret;
957 QSpacerItem * LuaBinder< QLayout >::spacerItem () {
958 bool absorbed = false;
959 int oldtop = lua_gettop(L);
960 lqtL_pushudata(L, this, "QLayout*");
961 if (lua_getmetatable(L, -1)) {
962 lua_getfield(L, -1, "spacerItem");
963 lua_remove(L, -2);
964 } else {
965 lua_pushnil(L);
967 lua_insert(L, -2);
968 if (lua_isfunction(L, -0-2)) {
969 lua_pcall(L, 0+1, 2, 0);
970 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
971 lua_pop(L, 1);
973 if (!absorbed) {
974 lua_settop(L, oldtop);
975 return this->QLayoutItem::spacerItem();
977 QSpacerItem * ret = *static_cast<QSpacerItem**>(lqtL_checkudata(L, -1, "QSpacerItem*"));
978 lua_settop(L, oldtop);
979 return ret;
981 QSize LuaBinder< QLayout >::sizeHint () const {
982 bool absorbed = false;
983 int oldtop = lua_gettop(L);
984 lqtL_pushudata(L, this, "QLayout*");
985 if (lua_getmetatable(L, -1)) {
986 lua_getfield(L, -1, "sizeHint");
987 lua_remove(L, -2);
988 } else {
989 lua_pushnil(L);
991 lua_insert(L, -2);
992 if (lua_isfunction(L, -0-2)) {
993 lua_pcall(L, 0+1, 2, 0);
994 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
995 lua_pop(L, 1);
997 if (!absorbed) {
998 lua_settop(L, oldtop);
1000 QSize ret = **static_cast<QSize**>(lqtL_checkudata(L, -1, "QSize*"));
1001 lua_settop(L, oldtop);
1002 return ret;
1004 QSize LuaBinder< QLayout >::minimumSize () const {
1005 bool absorbed = false;
1006 int oldtop = lua_gettop(L);
1007 lqtL_pushudata(L, this, "QLayout*");
1008 if (lua_getmetatable(L, -1)) {
1009 lua_getfield(L, -1, "minimumSize");
1010 lua_remove(L, -2);
1011 } else {
1012 lua_pushnil(L);
1014 lua_insert(L, -2);
1015 if (lua_isfunction(L, -0-2)) {
1016 lua_pcall(L, 0+1, 2, 0);
1017 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1018 lua_pop(L, 1);
1020 if (!absorbed) {
1021 lua_settop(L, oldtop);
1022 return this->QLayout::minimumSize();
1024 QSize ret = **static_cast<QSize**>(lqtL_checkudata(L, -1, "QSize*"));
1025 lua_settop(L, oldtop);
1026 return ret;
1028 bool LuaBinder< QLayout >::isEmpty () const {
1029 bool absorbed = false;
1030 int oldtop = lua_gettop(L);
1031 lqtL_pushudata(L, this, "QLayout*");
1032 if (lua_getmetatable(L, -1)) {
1033 lua_getfield(L, -1, "isEmpty");
1034 lua_remove(L, -2);
1035 } else {
1036 lua_pushnil(L);
1038 lua_insert(L, -2);
1039 if (lua_isfunction(L, -0-2)) {
1040 lua_pcall(L, 0+1, 2, 0);
1041 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1042 lua_pop(L, 1);
1044 if (!absorbed) {
1045 lua_settop(L, oldtop);
1046 return this->QLayout::isEmpty();
1048 bool ret = (bool)lua_toboolean(L, -1);
1049 lua_settop(L, oldtop);
1050 return ret;
1052 void LuaBinder< QLayout >::connectNotify (const char * arg1) {
1053 bool absorbed = false;
1054 int oldtop = lua_gettop(L);
1055 lqtL_pushudata(L, this, "QLayout*");
1056 if (lua_getmetatable(L, -1)) {
1057 lua_getfield(L, -1, "connectNotify");
1058 lua_remove(L, -2);
1059 } else {
1060 lua_pushnil(L);
1062 lua_insert(L, -2);
1063 lua_pushstring(L, arg1);
1064 if (lua_isfunction(L, -1-2)) {
1065 lua_pcall(L, 1+1, 2, 0);
1066 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1067 lua_pop(L, 1);
1069 if (!absorbed) {
1070 lua_settop(L, oldtop);
1071 this->QObject::connectNotify(arg1);
1073 lua_settop(L, oldtop);
1075 bool LuaBinder< QLayout >::event (QEvent * arg1) {
1076 bool absorbed = false;
1077 int oldtop = lua_gettop(L);
1078 lqtL_pushudata(L, this, "QLayout*");
1079 if (lua_getmetatable(L, -1)) {
1080 lua_getfield(L, -1, "event");
1081 lua_remove(L, -2);
1082 } else {
1083 lua_pushnil(L);
1085 lua_insert(L, -2);
1086 lqtL_pushudata(L, arg1, "QEvent*");
1087 if (lua_isfunction(L, -1-2)) {
1088 lua_pcall(L, 1+1, 2, 0);
1089 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1090 lua_pop(L, 1);
1092 if (!absorbed) {
1093 lua_settop(L, oldtop);
1094 return this->QObject::event(arg1);
1096 bool ret = (bool)lua_toboolean(L, -1);
1097 lua_settop(L, oldtop);
1098 return ret;
1100 void LuaBinder< QLayout >::timerEvent (QTimerEvent * arg1) {
1101 bool absorbed = false;
1102 int oldtop = lua_gettop(L);
1103 lqtL_pushudata(L, this, "QLayout*");
1104 if (lua_getmetatable(L, -1)) {
1105 lua_getfield(L, -1, "timerEvent");
1106 lua_remove(L, -2);
1107 } else {
1108 lua_pushnil(L);
1110 lua_insert(L, -2);
1111 lqtL_pushudata(L, arg1, "QTimerEvent*");
1112 if (lua_isfunction(L, -1-2)) {
1113 lua_pcall(L, 1+1, 2, 0);
1114 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1115 lua_pop(L, 1);
1117 if (!absorbed) {
1118 lua_settop(L, oldtop);
1119 this->QObject::timerEvent(arg1);
1121 lua_settop(L, oldtop);
1123 int LuaBinder< QLayout >::count () const {
1124 bool absorbed = false;
1125 int oldtop = lua_gettop(L);
1126 lqtL_pushudata(L, this, "QLayout*");
1127 if (lua_getmetatable(L, -1)) {
1128 lua_getfield(L, -1, "count");
1129 lua_remove(L, -2);
1130 } else {
1131 lua_pushnil(L);
1133 lua_insert(L, -2);
1134 if (lua_isfunction(L, -0-2)) {
1135 lua_pcall(L, 0+1, 2, 0);
1136 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1137 lua_pop(L, 1);
1139 if (!absorbed) {
1140 lua_settop(L, oldtop);
1142 int ret = lua_tointeger(L, -1);
1143 lua_settop(L, oldtop);
1144 return ret;
1146 void LuaBinder< QLayout >::disconnectNotify (const char * arg1) {
1147 bool absorbed = false;
1148 int oldtop = lua_gettop(L);
1149 lqtL_pushudata(L, this, "QLayout*");
1150 if (lua_getmetatable(L, -1)) {
1151 lua_getfield(L, -1, "disconnectNotify");
1152 lua_remove(L, -2);
1153 } else {
1154 lua_pushnil(L);
1156 lua_insert(L, -2);
1157 lua_pushstring(L, arg1);
1158 if (lua_isfunction(L, -1-2)) {
1159 lua_pcall(L, 1+1, 2, 0);
1160 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1161 lua_pop(L, 1);
1163 if (!absorbed) {
1164 lua_settop(L, oldtop);
1165 this->QObject::disconnectNotify(arg1);
1167 lua_settop(L, oldtop);
1169 QFlags<Qt::Orientation> LuaBinder< QLayout >::expandingDirections () const {
1170 bool absorbed = false;
1171 int oldtop = lua_gettop(L);
1172 lqtL_pushudata(L, this, "QLayout*");
1173 if (lua_getmetatable(L, -1)) {
1174 lua_getfield(L, -1, "expandingDirections");
1175 lua_remove(L, -2);
1176 } else {
1177 lua_pushnil(L);
1179 lua_insert(L, -2);
1180 if (lua_isfunction(L, -0-2)) {
1181 lua_pcall(L, 0+1, 2, 0);
1182 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1183 lua_pop(L, 1);
1185 if (!absorbed) {
1186 lua_settop(L, oldtop);
1187 return this->QLayout::expandingDirections();
1189 QFlags<Qt::Orientation> ret = **static_cast<QFlags<Qt::Orientation>**>(lqtL_checkudata(L, -1, "QFlags<Qt::Orientation>*"));
1190 lua_settop(L, oldtop);
1191 return ret;
1193 QRect LuaBinder< QLayout >::geometry () const {
1194 bool absorbed = false;
1195 int oldtop = lua_gettop(L);
1196 lqtL_pushudata(L, this, "QLayout*");
1197 if (lua_getmetatable(L, -1)) {
1198 lua_getfield(L, -1, "geometry");
1199 lua_remove(L, -2);
1200 } else {
1201 lua_pushnil(L);
1203 lua_insert(L, -2);
1204 if (lua_isfunction(L, -0-2)) {
1205 lua_pcall(L, 0+1, 2, 0);
1206 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1207 lua_pop(L, 1);
1209 if (!absorbed) {
1210 lua_settop(L, oldtop);
1211 return this->QLayout::geometry();
1213 QRect ret = **static_cast<QRect**>(lqtL_checkudata(L, -1, "QRect*"));
1214 lua_settop(L, oldtop);
1215 return ret;
1217 void LuaBinder< QLayout >::setGeometry (const QRect& arg1) {
1218 bool absorbed = false;
1219 int oldtop = lua_gettop(L);
1220 lqtL_pushudata(L, this, "QLayout*");
1221 if (lua_getmetatable(L, -1)) {
1222 lua_getfield(L, -1, "setGeometry");
1223 lua_remove(L, -2);
1224 } else {
1225 lua_pushnil(L);
1227 lua_insert(L, -2);
1228 lqtL_pushudata(L, &(arg1), "QRect*");
1229 if (lua_isfunction(L, -1-2)) {
1230 lua_pcall(L, 1+1, 2, 0);
1231 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1232 lua_pop(L, 1);
1234 if (!absorbed) {
1235 lua_settop(L, oldtop);
1237 lua_settop(L, oldtop);
1239 void LuaBinder< QLayout >::customEvent (QEvent * arg1) {
1240 bool absorbed = false;
1241 int oldtop = lua_gettop(L);
1242 lqtL_pushudata(L, this, "QLayout*");
1243 if (lua_getmetatable(L, -1)) {
1244 lua_getfield(L, -1, "customEvent");
1245 lua_remove(L, -2);
1246 } else {
1247 lua_pushnil(L);
1249 lua_insert(L, -2);
1250 lqtL_pushudata(L, arg1, "QEvent*");
1251 if (lua_isfunction(L, -1-2)) {
1252 lua_pcall(L, 1+1, 2, 0);
1253 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1254 lua_pop(L, 1);
1256 if (!absorbed) {
1257 lua_settop(L, oldtop);
1258 this->QObject::customEvent(arg1);
1260 lua_settop(L, oldtop);
1262 LuaBinder< QLayout >:: ~LuaBinder< QLayout > () {
1263 int oldtop = lua_gettop(L);
1264 lqtL_pushudata(L, this, "QLayout*");
1265 lua_getfield(L, -1, "~QLayout");
1267 if (lua_isfunction(L, -1)) {
1268 lua_insert(L, -2);
1269 lua_pcall(L, 1, 1, 0);
1270 } else {
1272 lua_settop(L, oldtop);
1274 int LuaBinder< QLayout >::lqt_pushenum_SizeConstraint (lua_State *L) {
1275 int enum_table = 0;
1276 lua_getfield(L, LUA_REGISTRYINDEX, LQT_ENUMS);
1277 if (!lua_istable(L, -1)) {
1278 lua_pop(L, 1);
1279 lua_newtable(L);
1280 lua_pushvalue(L, -1);
1281 lua_setfield(L, LUA_REGISTRYINDEX, LQT_ENUMS);
1283 lua_newtable(L);
1284 enum_table = lua_gettop(L);
1285 lua_pushstring(L, "SetDefaultConstraint");
1286 lua_rawseti(L, enum_table, 0);
1287 lua_pushinteger(L, 0);
1288 lua_setfield(L, enum_table, "SetDefaultConstraint");
1289 lua_pushstring(L, "SetNoConstraint");
1290 lua_rawseti(L, enum_table, 1);
1291 lua_pushinteger(L, 1);
1292 lua_setfield(L, enum_table, "SetNoConstraint");
1293 lua_pushstring(L, "SetMinimumSize");
1294 lua_rawseti(L, enum_table, 2);
1295 lua_pushinteger(L, 2);
1296 lua_setfield(L, enum_table, "SetMinimumSize");
1297 lua_pushstring(L, "SetFixedSize");
1298 lua_rawseti(L, enum_table, 3);
1299 lua_pushinteger(L, 3);
1300 lua_setfield(L, enum_table, "SetFixedSize");
1301 lua_pushstring(L, "SetMaximumSize");
1302 lua_rawseti(L, enum_table, 4);
1303 lua_pushinteger(L, 4);
1304 lua_setfield(L, enum_table, "SetMaximumSize");
1305 lua_pushstring(L, "SetMinAndMaxSize");
1306 lua_rawseti(L, enum_table, 5);
1307 lua_pushinteger(L, 5);
1308 lua_setfield(L, enum_table, "SetMinAndMaxSize");
1309 lua_pushcfunction(L, LuaBinder< QLayout >::lqt_pushenum_SizeConstraint_QFLAGS_CREATOR);
1310 lua_setfield(L, enum_table, "QFlags");
1311 lua_pushvalue(L, -1);
1312 lua_setfield(L, -3, "QLayout::SizeConstraint");
1313 lua_remove(L, -2);
1314 return 1;
1316 int LuaBinder< QLayout >::lqt_pushenum_SizeConstraint_QFLAGS_CREATOR (lua_State *L) {
1317 int argn = lua_gettop(L);
1318 int i = 0;
1319 void *p = lua_newuserdata(L, sizeof(QFlags<QLayout::SizeConstraint>*) + sizeof(QFlags<QLayout::SizeConstraint>));
1320 QFlags<QLayout::SizeConstraint> *fl = static_cast<QFlags<QLayout::SizeConstraint>*>( static_cast<void*>(&static_cast<QFlags<QLayout::SizeConstraint>**>(p)[1]) );
1321 *(void**)p = fl;
1322 for (i=1;i<=argn;i++) {
1323 *fl |= static_cast<QLayout::SizeConstraint>(lqtL_toenum(L, i, "QLayout::SizeConstraint"));
1325 if (luaL_newmetatable(L, "QFlags<QLayout::SizeConstraint>*")) {
1326 lua_pushstring(L, "QFlags<QLayout::SizeConstraint>*");
1327 lua_setfield(L, -2, "__qtype");
1329 lua_setmetatable(L, -2);
1330 return 1;
1332 int luaopen_QLayout (lua_State *L) {
1333 if (luaL_newmetatable(L, "QLayout*")) {
1334 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__indexOf);
1335 lua_setfield(L, -2, "indexOf");
1336 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__parentWidget);
1337 lua_setfield(L, -2, "parentWidget");
1338 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__minimumSize);
1339 lua_setfield(L, -2, "minimumSize");
1340 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__update);
1341 lua_setfield(L, -2, "update");
1342 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__trUtf8);
1343 lua_setfield(L, -2, "trUtf8");
1344 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__totalMaximumSize);
1345 lua_setfield(L, -2, "totalMaximumSize");
1346 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__tr);
1347 lua_setfield(L, -2, "tr");
1348 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__isEmpty);
1349 lua_setfield(L, -2, "isEmpty");
1350 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__setAlignment);
1351 lua_setfield(L, -2, "setAlignment");
1352 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__expandingDirections);
1353 lua_setfield(L, -2, "expandingDirections");
1354 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__addWidget);
1355 lua_setfield(L, -2, "addWidget");
1356 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__removeWidget);
1357 lua_setfield(L, -2, "removeWidget");
1358 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__activate);
1359 lua_setfield(L, -2, "activate");
1360 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__setMargin);
1361 lua_setfield(L, -2, "setMargin");
1362 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__delete);
1363 lua_setfield(L, -2, "delete");
1364 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__totalMinimumSize);
1365 lua_setfield(L, -2, "totalMinimumSize");
1366 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__layout);
1367 lua_setfield(L, -2, "layout");
1368 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__margin);
1369 lua_setfield(L, -2, "margin");
1370 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__menuBar);
1371 lua_setfield(L, -2, "menuBar");
1372 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__geometry);
1373 lua_setfield(L, -2, "geometry");
1374 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__spacing);
1375 lua_setfield(L, -2, "spacing");
1376 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__sizeConstraint);
1377 lua_setfield(L, -2, "sizeConstraint");
1378 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__setContentsMargins);
1379 lua_setfield(L, -2, "setContentsMargins");
1380 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__metaObject);
1381 lua_setfield(L, -2, "metaObject");
1382 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__new);
1383 lua_setfield(L, -2, "new");
1384 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__contentsRect);
1385 lua_setfield(L, -2, "contentsRect");
1386 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__getContentsMargins);
1387 lua_setfield(L, -2, "getContentsMargins");
1388 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__invalidate);
1389 lua_setfield(L, -2, "invalidate");
1390 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__maximumSize);
1391 lua_setfield(L, -2, "maximumSize");
1392 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__setMenuBar);
1393 lua_setfield(L, -2, "setMenuBar");
1394 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__totalSizeHint);
1395 lua_setfield(L, -2, "totalSizeHint");
1396 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__setSpacing);
1397 lua_setfield(L, -2, "setSpacing");
1398 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__closestAcceptableSize);
1399 lua_setfield(L, -2, "closestAcceptableSize");
1400 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__setSizeConstraint);
1401 lua_setfield(L, -2, "setSizeConstraint");
1402 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__isEnabled);
1403 lua_setfield(L, -2, "isEnabled");
1404 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__removeItem);
1405 lua_setfield(L, -2, "removeItem");
1406 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__setEnabled);
1407 lua_setfield(L, -2, "setEnabled");
1408 lua_pushcfunction(L, LuaBinder< QLayout >::__LuaWrapCall__totalHeightForWidth);
1409 lua_setfield(L, -2, "totalHeightForWidth");
1410 LuaBinder< QLayout >::lqt_pushenum_SizeConstraint(L);
1411 lua_setfield(L, -2, "SizeConstraint");
1412 lua_newtable(L);
1413 lua_pushboolean(L, 1);
1414 lua_setfield(L, -2, "QObject*");
1415 lua_pushboolean(L, 1);
1416 lua_setfield(L, -2, "QLayoutItem*");
1417 lua_setfield(L, -2, "__base");
1418 lua_pushcfunction(L, lqtL_newindex);
1419 lua_setfield(L, -2, "__newindex");
1420 lua_pushcfunction(L, lqtL_index);
1421 lua_setfield(L, -2, "__index");
1422 lua_pushcfunction(L, lqtL_gc);
1423 lua_setfield(L, -2, "__gc");
1424 lua_pushstring(L, "QLayout");
1425 lua_setfield(L, -2, "__qtype");
1426 lua_setglobal(L, "QLayout");
1427 } else {
1428 lua_pop(L, 1);
1430 return 0;