added "install" instruction
[Leditor.git] / src / lqt_bind_QTextCharFormat.cpp
blob0a65cddf2ba7f704fa2d4dfb6195f30dcf2040b4
1 #include "lqt_bind_QTextCharFormat.hpp"
3 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontFamily (lua_State *L) {
4 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
5 if (__lua__obj==0) {
6 lua_pushstring(L, "trying to reference deleted pointer");
7 lua_error(L);
8 return 0;
10 const QString& arg1 = QString::fromAscii(lua_tostring(L, 2), lua_objlen(L, 2));
11 __lua__obj->QTextCharFormat::setFontFamily(arg1);
12 return 0;
14 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontItalic (lua_State *L) {
15 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
16 if (__lua__obj==0) {
17 lua_pushstring(L, "trying to reference deleted pointer");
18 lua_error(L);
19 return 0;
21 bool arg1 = (bool)lua_toboolean(L, 2);
22 __lua__obj->QTextCharFormat::setFontItalic(arg1);
23 return 0;
25 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setUnderlineColor (lua_State *L) {
26 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
27 if (__lua__obj==0) {
28 lua_pushstring(L, "trying to reference deleted pointer");
29 lua_error(L);
30 return 0;
32 const QColor& arg1 = **static_cast<QColor**>(lqtL_checkudata(L, 2, "QColor*"));
33 __lua__obj->QTextCharFormat::setUnderlineColor(arg1);
34 return 0;
36 int LuaBinder< QTextCharFormat >::__LuaWrapCall__fontFamily (lua_State *L) {
37 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
38 if (__lua__obj==0) {
39 lua_pushstring(L, "trying to reference deleted pointer");
40 lua_error(L);
41 return 0;
43 QString ret = __lua__obj->QTextCharFormat::fontFamily();
44 lua_pushlstring(L, ret.toAscii().data(), ret.toAscii().size());
45 return 1;
47 int LuaBinder< QTextCharFormat >::__LuaWrapCall__fontItalic (lua_State *L) {
48 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
49 if (__lua__obj==0) {
50 lua_pushstring(L, "trying to reference deleted pointer");
51 lua_error(L);
52 return 0;
54 bool ret = __lua__obj->QTextCharFormat::fontItalic();
55 lua_pushboolean(L, ret);
56 return 1;
58 int LuaBinder< QTextCharFormat >::__LuaWrapCall__underlineColor (lua_State *L) {
59 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
60 if (__lua__obj==0) {
61 lua_pushstring(L, "trying to reference deleted pointer");
62 lua_error(L);
63 return 0;
65 QColor ret = __lua__obj->QTextCharFormat::underlineColor();
66 lqtL_passudata(L, new QColor(ret), "QColor*");
67 return 1;
69 int LuaBinder< QTextCharFormat >::__LuaWrapCall__tableCellRowSpan (lua_State *L) {
70 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
71 if (__lua__obj==0) {
72 lua_pushstring(L, "trying to reference deleted pointer");
73 lua_error(L);
74 return 0;
76 int ret = __lua__obj->QTextCharFormat::tableCellRowSpan();
77 lua_pushinteger(L, ret);
78 return 1;
80 int LuaBinder< QTextCharFormat >::__LuaWrapCall__fontWeight (lua_State *L) {
81 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
82 if (__lua__obj==0) {
83 lua_pushstring(L, "trying to reference deleted pointer");
84 lua_error(L);
85 return 0;
87 int ret = __lua__obj->QTextCharFormat::fontWeight();
88 lua_pushinteger(L, ret);
89 return 1;
91 int LuaBinder< QTextCharFormat >::__LuaWrapCall__isValid (lua_State *L) {
92 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
93 if (__lua__obj==0) {
94 lua_pushstring(L, "trying to reference deleted pointer");
95 lua_error(L);
96 return 0;
98 bool ret = __lua__obj->QTextCharFormat::isValid();
99 lua_pushboolean(L, ret);
100 return 1;
102 int LuaBinder< QTextCharFormat >::__LuaWrapCall__fontOverline (lua_State *L) {
103 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
104 if (__lua__obj==0) {
105 lua_pushstring(L, "trying to reference deleted pointer");
106 lua_error(L);
107 return 0;
109 bool ret = __lua__obj->QTextCharFormat::fontOverline();
110 lua_pushboolean(L, ret);
111 return 1;
113 int LuaBinder< QTextCharFormat >::__LuaWrapCall__fontPointSize (lua_State *L) {
114 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
115 if (__lua__obj==0) {
116 lua_pushstring(L, "trying to reference deleted pointer");
117 lua_error(L);
118 return 0;
120 double ret = __lua__obj->QTextCharFormat::fontPointSize();
121 lua_pushnumber(L, ret);
122 return 1;
124 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setTableCellRowSpan (lua_State *L) {
125 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
126 if (__lua__obj==0) {
127 lua_pushstring(L, "trying to reference deleted pointer");
128 lua_error(L);
129 return 0;
131 int arg1 = lua_tointeger(L, 2);
132 __lua__obj->QTextCharFormat::setTableCellRowSpan(arg1);
133 return 0;
135 int LuaBinder< QTextCharFormat >::__LuaWrapCall__font (lua_State *L) {
136 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
137 if (__lua__obj==0) {
138 lua_pushstring(L, "trying to reference deleted pointer");
139 lua_error(L);
140 return 0;
142 QFont ret = __lua__obj->QTextCharFormat::font();
143 lqtL_passudata(L, new QFont(ret), "QFont*");
144 return 1;
146 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setTableCellColumnSpan (lua_State *L) {
147 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
148 if (__lua__obj==0) {
149 lua_pushstring(L, "trying to reference deleted pointer");
150 lua_error(L);
151 return 0;
153 int arg1 = lua_tointeger(L, 2);
154 __lua__obj->QTextCharFormat::setTableCellColumnSpan(arg1);
155 return 0;
157 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setAnchorHref (lua_State *L) {
158 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
159 if (__lua__obj==0) {
160 lua_pushstring(L, "trying to reference deleted pointer");
161 lua_error(L);
162 return 0;
164 const QString& arg1 = QString::fromAscii(lua_tostring(L, 2), lua_objlen(L, 2));
165 __lua__obj->QTextCharFormat::setAnchorHref(arg1);
166 return 0;
168 int LuaBinder< QTextCharFormat >::__LuaWrapCall__anchorHref (lua_State *L) {
169 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
170 if (__lua__obj==0) {
171 lua_pushstring(L, "trying to reference deleted pointer");
172 lua_error(L);
173 return 0;
175 QString ret = __lua__obj->QTextCharFormat::anchorHref();
176 lua_pushlstring(L, ret.toAscii().data(), ret.toAscii().size());
177 return 1;
179 int LuaBinder< QTextCharFormat >::__LuaWrapCall__fontFixedPitch (lua_State *L) {
180 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
181 if (__lua__obj==0) {
182 lua_pushstring(L, "trying to reference deleted pointer");
183 lua_error(L);
184 return 0;
186 bool ret = __lua__obj->QTextCharFormat::fontFixedPitch();
187 lua_pushboolean(L, ret);
188 return 1;
190 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontPointSize (lua_State *L) {
191 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
192 if (__lua__obj==0) {
193 lua_pushstring(L, "trying to reference deleted pointer");
194 lua_error(L);
195 return 0;
197 double arg1 = lua_tonumber(L, 2);
198 __lua__obj->QTextCharFormat::setFontPointSize(arg1);
199 return 0;
201 int LuaBinder< QTextCharFormat >::__LuaWrapCall__verticalAlignment (lua_State *L) {
202 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
203 if (__lua__obj==0) {
204 lua_pushstring(L, "trying to reference deleted pointer");
205 lua_error(L);
206 return 0;
208 QTextCharFormat::VerticalAlignment ret = __lua__obj->QTextCharFormat::verticalAlignment();
209 lqtL_pushenum(L, ret, "QTextCharFormat::VerticalAlignment");
210 return 1;
212 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setTextOutline (lua_State *L) {
213 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
214 if (__lua__obj==0) {
215 lua_pushstring(L, "trying to reference deleted pointer");
216 lua_error(L);
217 return 0;
219 const QPen& arg1 = **static_cast<QPen**>(lqtL_checkudata(L, 2, "QPen*"));
220 __lua__obj->QTextCharFormat::setTextOutline(arg1);
221 return 0;
223 int LuaBinder< QTextCharFormat >::__LuaWrapCall__underlineStyle (lua_State *L) {
224 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
225 if (__lua__obj==0) {
226 lua_pushstring(L, "trying to reference deleted pointer");
227 lua_error(L);
228 return 0;
230 QTextCharFormat::UnderlineStyle ret = __lua__obj->QTextCharFormat::underlineStyle();
231 lqtL_pushenum(L, ret, "QTextCharFormat::UnderlineStyle");
232 return 1;
234 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontUnderline (lua_State *L) {
235 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
236 if (__lua__obj==0) {
237 lua_pushstring(L, "trying to reference deleted pointer");
238 lua_error(L);
239 return 0;
241 bool arg1 = (bool)lua_toboolean(L, 2);
242 __lua__obj->QTextCharFormat::setFontUnderline(arg1);
243 return 0;
245 int LuaBinder< QTextCharFormat >::__LuaWrapCall__isAnchor (lua_State *L) {
246 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
247 if (__lua__obj==0) {
248 lua_pushstring(L, "trying to reference deleted pointer");
249 lua_error(L);
250 return 0;
252 bool ret = __lua__obj->QTextCharFormat::isAnchor();
253 lua_pushboolean(L, ret);
254 return 1;
256 int LuaBinder< QTextCharFormat >::__LuaWrapCall__textOutline (lua_State *L) {
257 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
258 if (__lua__obj==0) {
259 lua_pushstring(L, "trying to reference deleted pointer");
260 lua_error(L);
261 return 0;
263 QPen ret = __lua__obj->QTextCharFormat::textOutline();
264 lqtL_passudata(L, new QPen(ret), "QPen*");
265 return 1;
267 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontStrikeOut (lua_State *L) {
268 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
269 if (__lua__obj==0) {
270 lua_pushstring(L, "trying to reference deleted pointer");
271 lua_error(L);
272 return 0;
274 bool arg1 = (bool)lua_toboolean(L, 2);
275 __lua__obj->QTextCharFormat::setFontStrikeOut(arg1);
276 return 0;
278 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontWeight (lua_State *L) {
279 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
280 if (__lua__obj==0) {
281 lua_pushstring(L, "trying to reference deleted pointer");
282 lua_error(L);
283 return 0;
285 int arg1 = lua_tointeger(L, 2);
286 __lua__obj->QTextCharFormat::setFontWeight(arg1);
287 return 0;
289 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontFixedPitch (lua_State *L) {
290 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
291 if (__lua__obj==0) {
292 lua_pushstring(L, "trying to reference deleted pointer");
293 lua_error(L);
294 return 0;
296 bool arg1 = (bool)lua_toboolean(L, 2);
297 __lua__obj->QTextCharFormat::setFontFixedPitch(arg1);
298 return 0;
300 int LuaBinder< QTextCharFormat >::__LuaWrapCall__delete (lua_State *L) {
301 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
302 if (__lua__obj==0) {
303 lua_pushstring(L, "trying to reference deleted pointer");
304 lua_error(L);
305 return 0;
307 delete __lua__obj;
308 __lua__obj = 0;
309 return 0;
311 int LuaBinder< QTextCharFormat >::__LuaWrapCall__anchorName (lua_State *L) {
312 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
313 if (__lua__obj==0) {
314 lua_pushstring(L, "trying to reference deleted pointer");
315 lua_error(L);
316 return 0;
318 QString ret = __lua__obj->QTextCharFormat::anchorName();
319 lua_pushlstring(L, ret.toAscii().data(), ret.toAscii().size());
320 return 1;
322 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setAnchor (lua_State *L) {
323 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
324 if (__lua__obj==0) {
325 lua_pushstring(L, "trying to reference deleted pointer");
326 lua_error(L);
327 return 0;
329 bool arg1 = (bool)lua_toboolean(L, 2);
330 __lua__obj->QTextCharFormat::setAnchor(arg1);
331 return 0;
333 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setUnderlineStyle (lua_State *L) {
334 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
335 if (__lua__obj==0) {
336 lua_pushstring(L, "trying to reference deleted pointer");
337 lua_error(L);
338 return 0;
340 QTextCharFormat::UnderlineStyle arg1 = static_cast<QTextCharFormat::UnderlineStyle>(lqtL_toenum(L, 2, "QTextCharFormat::UnderlineStyle"));
341 __lua__obj->QTextCharFormat::setUnderlineStyle(arg1);
342 return 0;
344 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setToolTip (lua_State *L) {
345 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
346 if (__lua__obj==0) {
347 lua_pushstring(L, "trying to reference deleted pointer");
348 lua_error(L);
349 return 0;
351 const QString& arg1 = QString::fromAscii(lua_tostring(L, 2), lua_objlen(L, 2));
352 __lua__obj->QTextCharFormat::setToolTip(arg1);
353 return 0;
355 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setAnchorName (lua_State *L) {
356 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
357 if (__lua__obj==0) {
358 lua_pushstring(L, "trying to reference deleted pointer");
359 lua_error(L);
360 return 0;
362 const QString& arg1 = QString::fromAscii(lua_tostring(L, 2), lua_objlen(L, 2));
363 __lua__obj->QTextCharFormat::setAnchorName(arg1);
364 return 0;
366 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontOverline (lua_State *L) {
367 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
368 if (__lua__obj==0) {
369 lua_pushstring(L, "trying to reference deleted pointer");
370 lua_error(L);
371 return 0;
373 bool arg1 = (bool)lua_toboolean(L, 2);
374 __lua__obj->QTextCharFormat::setFontOverline(arg1);
375 return 0;
377 int LuaBinder< QTextCharFormat >::__LuaWrapCall__tableCellColumnSpan (lua_State *L) {
378 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
379 if (__lua__obj==0) {
380 lua_pushstring(L, "trying to reference deleted pointer");
381 lua_error(L);
382 return 0;
384 int ret = __lua__obj->QTextCharFormat::tableCellColumnSpan();
385 lua_pushinteger(L, ret);
386 return 1;
388 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setVerticalAlignment (lua_State *L) {
389 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
390 if (__lua__obj==0) {
391 lua_pushstring(L, "trying to reference deleted pointer");
392 lua_error(L);
393 return 0;
395 QTextCharFormat::VerticalAlignment arg1 = static_cast<QTextCharFormat::VerticalAlignment>(lqtL_toenum(L, 2, "QTextCharFormat::VerticalAlignment"));
396 __lua__obj->QTextCharFormat::setVerticalAlignment(arg1);
397 return 0;
399 int LuaBinder< QTextCharFormat >::__LuaWrapCall__fontStrikeOut (lua_State *L) {
400 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
401 if (__lua__obj==0) {
402 lua_pushstring(L, "trying to reference deleted pointer");
403 lua_error(L);
404 return 0;
406 bool ret = __lua__obj->QTextCharFormat::fontStrikeOut();
407 lua_pushboolean(L, ret);
408 return 1;
410 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setAnchorNames (lua_State *L) {
411 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
412 if (__lua__obj==0) {
413 lua_pushstring(L, "trying to reference deleted pointer");
414 lua_error(L);
415 return 0;
417 const QStringList& arg1 = **static_cast<QStringList**>(lqtL_checkudata(L, 2, "QStringList*"));
418 __lua__obj->QTextCharFormat::setAnchorNames(arg1);
419 return 0;
421 int LuaBinder< QTextCharFormat >::__LuaWrapCall__toolTip (lua_State *L) {
422 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
423 if (__lua__obj==0) {
424 lua_pushstring(L, "trying to reference deleted pointer");
425 lua_error(L);
426 return 0;
428 QString ret = __lua__obj->QTextCharFormat::toolTip();
429 lua_pushlstring(L, ret.toAscii().data(), ret.toAscii().size());
430 return 1;
432 int LuaBinder< QTextCharFormat >::__LuaWrapCall__setFont (lua_State *L) {
433 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
434 if (__lua__obj==0) {
435 lua_pushstring(L, "trying to reference deleted pointer");
436 lua_error(L);
437 return 0;
439 const QFont& arg1 = **static_cast<QFont**>(lqtL_checkudata(L, 2, "QFont*"));
440 __lua__obj->QTextCharFormat::setFont(arg1);
441 return 0;
443 int LuaBinder< QTextCharFormat >::__LuaWrapCall__fontUnderline (lua_State *L) {
444 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
445 if (__lua__obj==0) {
446 lua_pushstring(L, "trying to reference deleted pointer");
447 lua_error(L);
448 return 0;
450 bool ret = __lua__obj->QTextCharFormat::fontUnderline();
451 lua_pushboolean(L, ret);
452 return 1;
454 int LuaBinder< QTextCharFormat >::__LuaWrapCall__anchorNames (lua_State *L) {
455 QTextCharFormat *& __lua__obj = *static_cast<QTextCharFormat**>(lqtL_checkudata(L, 1, "QTextCharFormat*"));
456 if (__lua__obj==0) {
457 lua_pushstring(L, "trying to reference deleted pointer");
458 lua_error(L);
459 return 0;
461 QStringList ret = __lua__obj->QTextCharFormat::anchorNames();
462 lqtL_passudata(L, new QStringList(ret), "QStringList*");
463 return 1;
465 int LuaBinder< QTextCharFormat >::lqt_pushenum_VerticalAlignment (lua_State *L) {
466 int enum_table = 0;
467 lua_getfield(L, LUA_REGISTRYINDEX, LQT_ENUMS);
468 if (!lua_istable(L, -1)) {
469 lua_pop(L, 1);
470 lua_newtable(L);
471 lua_pushvalue(L, -1);
472 lua_setfield(L, LUA_REGISTRYINDEX, LQT_ENUMS);
474 lua_newtable(L);
475 enum_table = lua_gettop(L);
476 lua_pushstring(L, "AlignNormal");
477 lua_rawseti(L, enum_table, 0);
478 lua_pushinteger(L, 0);
479 lua_setfield(L, enum_table, "AlignNormal");
480 lua_pushstring(L, "AlignSuperScript");
481 lua_rawseti(L, enum_table, 1);
482 lua_pushinteger(L, 1);
483 lua_setfield(L, enum_table, "AlignSuperScript");
484 lua_pushstring(L, "AlignSubScript");
485 lua_rawseti(L, enum_table, 2);
486 lua_pushinteger(L, 2);
487 lua_setfield(L, enum_table, "AlignSubScript");
488 lua_pushstring(L, "AlignMiddle");
489 lua_rawseti(L, enum_table, 3);
490 lua_pushinteger(L, 3);
491 lua_setfield(L, enum_table, "AlignMiddle");
492 lua_pushstring(L, "AlignTop");
493 lua_rawseti(L, enum_table, 4);
494 lua_pushinteger(L, 4);
495 lua_setfield(L, enum_table, "AlignTop");
496 lua_pushstring(L, "AlignBottom");
497 lua_rawseti(L, enum_table, 5);
498 lua_pushinteger(L, 5);
499 lua_setfield(L, enum_table, "AlignBottom");
500 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::lqt_pushenum_VerticalAlignment_QFLAGS_CREATOR);
501 lua_setfield(L, enum_table, "QFlags");
502 lua_pushvalue(L, -1);
503 lua_setfield(L, -3, "QTextCharFormat::VerticalAlignment");
504 lua_remove(L, -2);
505 return 1;
507 int LuaBinder< QTextCharFormat >::lqt_pushenum_VerticalAlignment_QFLAGS_CREATOR (lua_State *L) {
508 int argn = lua_gettop(L);
509 int i = 0;
510 void *p = lua_newuserdata(L, sizeof(QFlags<QTextCharFormat::VerticalAlignment>*) + sizeof(QFlags<QTextCharFormat::VerticalAlignment>));
511 QFlags<QTextCharFormat::VerticalAlignment> *fl = static_cast<QFlags<QTextCharFormat::VerticalAlignment>*>( static_cast<void*>(&static_cast<QFlags<QTextCharFormat::VerticalAlignment>**>(p)[1]) );
512 *(void**)p = fl;
513 for (i=1;i<=argn;i++) {
514 *fl |= static_cast<QTextCharFormat::VerticalAlignment>(lqtL_toenum(L, i, "QTextCharFormat::VerticalAlignment"));
516 if (luaL_newmetatable(L, "QFlags<QTextCharFormat::VerticalAlignment>*")) {
517 lua_pushstring(L, "QFlags<QTextCharFormat::VerticalAlignment>*");
518 lua_setfield(L, -2, "__qtype");
520 lua_setmetatable(L, -2);
521 return 1;
523 int LuaBinder< QTextCharFormat >::lqt_pushenum_UnderlineStyle (lua_State *L) {
524 int enum_table = 0;
525 lua_getfield(L, LUA_REGISTRYINDEX, LQT_ENUMS);
526 if (!lua_istable(L, -1)) {
527 lua_pop(L, 1);
528 lua_newtable(L);
529 lua_pushvalue(L, -1);
530 lua_setfield(L, LUA_REGISTRYINDEX, LQT_ENUMS);
532 lua_newtable(L);
533 enum_table = lua_gettop(L);
534 lua_pushstring(L, "NoUnderline");
535 lua_rawseti(L, enum_table, 0);
536 lua_pushinteger(L, 0);
537 lua_setfield(L, enum_table, "NoUnderline");
538 lua_pushstring(L, "SingleUnderline");
539 lua_rawseti(L, enum_table, 1);
540 lua_pushinteger(L, 1);
541 lua_setfield(L, enum_table, "SingleUnderline");
542 lua_pushstring(L, "DashUnderline");
543 lua_rawseti(L, enum_table, 2);
544 lua_pushinteger(L, 2);
545 lua_setfield(L, enum_table, "DashUnderline");
546 lua_pushstring(L, "DotLine");
547 lua_rawseti(L, enum_table, 3);
548 lua_pushinteger(L, 3);
549 lua_setfield(L, enum_table, "DotLine");
550 lua_pushstring(L, "DashDotLine");
551 lua_rawseti(L, enum_table, 4);
552 lua_pushinteger(L, 4);
553 lua_setfield(L, enum_table, "DashDotLine");
554 lua_pushstring(L, "DashDotDotLine");
555 lua_rawseti(L, enum_table, 5);
556 lua_pushinteger(L, 5);
557 lua_setfield(L, enum_table, "DashDotDotLine");
558 lua_pushstring(L, "WaveUnderline");
559 lua_rawseti(L, enum_table, 6);
560 lua_pushinteger(L, 6);
561 lua_setfield(L, enum_table, "WaveUnderline");
562 lua_pushstring(L, "SpellCheckUnderline");
563 lua_rawseti(L, enum_table, 7);
564 lua_pushinteger(L, 7);
565 lua_setfield(L, enum_table, "SpellCheckUnderline");
566 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::lqt_pushenum_UnderlineStyle_QFLAGS_CREATOR);
567 lua_setfield(L, enum_table, "QFlags");
568 lua_pushvalue(L, -1);
569 lua_setfield(L, -3, "QTextCharFormat::UnderlineStyle");
570 lua_remove(L, -2);
571 return 1;
573 int LuaBinder< QTextCharFormat >::lqt_pushenum_UnderlineStyle_QFLAGS_CREATOR (lua_State *L) {
574 int argn = lua_gettop(L);
575 int i = 0;
576 void *p = lua_newuserdata(L, sizeof(QFlags<QTextCharFormat::UnderlineStyle>*) + sizeof(QFlags<QTextCharFormat::UnderlineStyle>));
577 QFlags<QTextCharFormat::UnderlineStyle> *fl = static_cast<QFlags<QTextCharFormat::UnderlineStyle>*>( static_cast<void*>(&static_cast<QFlags<QTextCharFormat::UnderlineStyle>**>(p)[1]) );
578 *(void**)p = fl;
579 for (i=1;i<=argn;i++) {
580 *fl |= static_cast<QTextCharFormat::UnderlineStyle>(lqtL_toenum(L, i, "QTextCharFormat::UnderlineStyle"));
582 if (luaL_newmetatable(L, "QFlags<QTextCharFormat::UnderlineStyle>*")) {
583 lua_pushstring(L, "QFlags<QTextCharFormat::UnderlineStyle>*");
584 lua_setfield(L, -2, "__qtype");
586 lua_setmetatable(L, -2);
587 return 1;
589 int luaopen_QTextCharFormat (lua_State *L) {
590 if (luaL_newmetatable(L, "QTextCharFormat*")) {
591 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontFamily);
592 lua_setfield(L, -2, "setFontFamily");
593 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontItalic);
594 lua_setfield(L, -2, "setFontItalic");
595 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setUnderlineColor);
596 lua_setfield(L, -2, "setUnderlineColor");
597 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__fontFamily);
598 lua_setfield(L, -2, "fontFamily");
599 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__fontItalic);
600 lua_setfield(L, -2, "fontItalic");
601 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__underlineColor);
602 lua_setfield(L, -2, "underlineColor");
603 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__tableCellRowSpan);
604 lua_setfield(L, -2, "tableCellRowSpan");
605 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__fontWeight);
606 lua_setfield(L, -2, "fontWeight");
607 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__isValid);
608 lua_setfield(L, -2, "isValid");
609 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__fontOverline);
610 lua_setfield(L, -2, "fontOverline");
611 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__fontPointSize);
612 lua_setfield(L, -2, "fontPointSize");
613 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setTableCellRowSpan);
614 lua_setfield(L, -2, "setTableCellRowSpan");
615 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__font);
616 lua_setfield(L, -2, "font");
617 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setTableCellColumnSpan);
618 lua_setfield(L, -2, "setTableCellColumnSpan");
619 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setAnchorHref);
620 lua_setfield(L, -2, "setAnchorHref");
621 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__anchorHref);
622 lua_setfield(L, -2, "anchorHref");
623 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__fontFixedPitch);
624 lua_setfield(L, -2, "fontFixedPitch");
625 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontPointSize);
626 lua_setfield(L, -2, "setFontPointSize");
627 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__verticalAlignment);
628 lua_setfield(L, -2, "verticalAlignment");
629 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setTextOutline);
630 lua_setfield(L, -2, "setTextOutline");
631 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__underlineStyle);
632 lua_setfield(L, -2, "underlineStyle");
633 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontUnderline);
634 lua_setfield(L, -2, "setFontUnderline");
635 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__isAnchor);
636 lua_setfield(L, -2, "isAnchor");
637 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__textOutline);
638 lua_setfield(L, -2, "textOutline");
639 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontStrikeOut);
640 lua_setfield(L, -2, "setFontStrikeOut");
641 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontWeight);
642 lua_setfield(L, -2, "setFontWeight");
643 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontFixedPitch);
644 lua_setfield(L, -2, "setFontFixedPitch");
645 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__delete);
646 lua_setfield(L, -2, "delete");
647 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__anchorName);
648 lua_setfield(L, -2, "anchorName");
649 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setAnchor);
650 lua_setfield(L, -2, "setAnchor");
651 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setUnderlineStyle);
652 lua_setfield(L, -2, "setUnderlineStyle");
653 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setToolTip);
654 lua_setfield(L, -2, "setToolTip");
655 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setAnchorName);
656 lua_setfield(L, -2, "setAnchorName");
657 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setFontOverline);
658 lua_setfield(L, -2, "setFontOverline");
659 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__tableCellColumnSpan);
660 lua_setfield(L, -2, "tableCellColumnSpan");
661 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setVerticalAlignment);
662 lua_setfield(L, -2, "setVerticalAlignment");
663 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__fontStrikeOut);
664 lua_setfield(L, -2, "fontStrikeOut");
665 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setAnchorNames);
666 lua_setfield(L, -2, "setAnchorNames");
667 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__toolTip);
668 lua_setfield(L, -2, "toolTip");
669 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__setFont);
670 lua_setfield(L, -2, "setFont");
671 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__fontUnderline);
672 lua_setfield(L, -2, "fontUnderline");
673 lua_pushcfunction(L, LuaBinder< QTextCharFormat >::__LuaWrapCall__anchorNames);
674 lua_setfield(L, -2, "anchorNames");
675 LuaBinder< QTextCharFormat >::lqt_pushenum_VerticalAlignment(L);
676 lua_setfield(L, -2, "VerticalAlignment");
677 LuaBinder< QTextCharFormat >::lqt_pushenum_UnderlineStyle(L);
678 lua_setfield(L, -2, "UnderlineStyle");
679 lua_newtable(L);
680 lua_pushboolean(L, 1);
681 lua_setfield(L, -2, "QTextFormat*");
682 lua_setfield(L, -2, "__base");
683 lua_pushcfunction(L, lqtL_newindex);
684 lua_setfield(L, -2, "__newindex");
685 lua_pushcfunction(L, lqtL_index);
686 lua_setfield(L, -2, "__index");
687 lua_pushcfunction(L, lqtL_gc);
688 lua_setfield(L, -2, "__gc");
689 lua_pushstring(L, "QTextCharFormat");
690 lua_setfield(L, -2, "__qtype");
691 lua_setglobal(L, "QTextCharFormat");
692 } else {
693 lua_pop(L, 1);
695 return 0;