1 //******************************************************************************
2 //  Copyright (c) 2005-2013 by Jan Van hijfte
3 //
4 //  See the included file COPYING.TXT for details about the copyright.
5 //
6 //  This program is distributed in the hope that it will be useful,
7 //  but WITHOUT ANY WARRANTY; without even the implied warranty of
8 //  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
9 //******************************************************************************
10 
11 
12 #include "qlabel_c.h"
13 
QLabel_Create(QWidgetH parent,unsigned int f)14 QLabelH QLabel_Create(QWidgetH parent, unsigned int f)
15 {
16 	return (QLabelH) new QLabel((QWidget*)parent, (Qt::WindowFlags)f);
17 }
18 
QLabel_Destroy(QLabelH handle)19 void QLabel_Destroy(QLabelH handle)
20 {
21 	delete (QLabel *)handle;
22 }
23 
QLabel_Create2(PWideString text,QWidgetH parent,unsigned int f)24 QLabelH QLabel_Create2(PWideString text, QWidgetH parent, unsigned int f)
25 {
26 	QString t_text;
27 	copyPWideStringToQString(text, t_text);
28 	return (QLabelH) new QLabel(t_text, (QWidget*)parent, (Qt::WindowFlags)f);
29 }
30 
QLabel_text(QLabelH handle,PWideString retval)31 void QLabel_text(QLabelH handle, PWideString retval)
32 {
33 	QString t_retval;
34 	t_retval = ((QLabel *)handle)->text();
35 	copyQStringToPWideString(t_retval, retval);
36 }
37 
QLabel_pixmap(QLabelH handle)38 const QPixmapH QLabel_pixmap(QLabelH handle)
39 {
40 	return (const QPixmapH) ((QLabel *)handle)->pixmap();
41 }
42 
QLabel_picture(QLabelH handle)43 const QPictureH QLabel_picture(QLabelH handle)
44 {
45 	return (const QPictureH) ((QLabel *)handle)->picture();
46 }
47 
QLabel_movie(QLabelH handle)48 QMovieH QLabel_movie(QLabelH handle)
49 {
50 	return (QMovieH) ((QLabel *)handle)->movie();
51 }
52 
QLabel_textFormat(QLabelH handle)53 Qt::TextFormat QLabel_textFormat(QLabelH handle)
54 {
55 	return (Qt::TextFormat) ((QLabel *)handle)->textFormat();
56 }
57 
QLabel_setTextFormat(QLabelH handle,Qt::TextFormat AnonParam1)58 void QLabel_setTextFormat(QLabelH handle, Qt::TextFormat AnonParam1)
59 {
60 	((QLabel *)handle)->setTextFormat(AnonParam1);
61 }
62 
QLabel_alignment(QLabelH handle)63 unsigned int QLabel_alignment(QLabelH handle)
64 {
65 	return (unsigned int) ((QLabel *)handle)->alignment();
66 }
67 
QLabel_setAlignment(QLabelH handle,unsigned int AnonParam1)68 void QLabel_setAlignment(QLabelH handle, unsigned int AnonParam1)
69 {
70 	((QLabel *)handle)->setAlignment((Qt::Alignment)AnonParam1);
71 }
72 
QLabel_setWordWrap(QLabelH handle,bool on)73 void QLabel_setWordWrap(QLabelH handle, bool on)
74 {
75 	((QLabel *)handle)->setWordWrap(on);
76 }
77 
QLabel_wordWrap(QLabelH handle)78 bool QLabel_wordWrap(QLabelH handle)
79 {
80 	return (bool) ((QLabel *)handle)->wordWrap();
81 }
82 
QLabel_indent(QLabelH handle)83 int QLabel_indent(QLabelH handle)
84 {
85 	return (int) ((QLabel *)handle)->indent();
86 }
87 
QLabel_setIndent(QLabelH handle,int AnonParam1)88 void QLabel_setIndent(QLabelH handle, int AnonParam1)
89 {
90 	((QLabel *)handle)->setIndent(AnonParam1);
91 }
92 
QLabel_margin(QLabelH handle)93 int QLabel_margin(QLabelH handle)
94 {
95 	return (int) ((QLabel *)handle)->margin();
96 }
97 
QLabel_setMargin(QLabelH handle,int AnonParam1)98 void QLabel_setMargin(QLabelH handle, int AnonParam1)
99 {
100 	((QLabel *)handle)->setMargin(AnonParam1);
101 }
102 
QLabel_hasScaledContents(QLabelH handle)103 bool QLabel_hasScaledContents(QLabelH handle)
104 {
105 	return (bool) ((QLabel *)handle)->hasScaledContents();
106 }
107 
QLabel_setScaledContents(QLabelH handle,bool AnonParam1)108 void QLabel_setScaledContents(QLabelH handle, bool AnonParam1)
109 {
110 	((QLabel *)handle)->setScaledContents(AnonParam1);
111 }
112 
QLabel_sizeHint(QLabelH handle,PSize retval)113 void QLabel_sizeHint(QLabelH handle, PSize retval)
114 {
115 	*(QSize *)retval = ((QLabel *)handle)->sizeHint();
116 }
117 
QLabel_minimumSizeHint(QLabelH handle,PSize retval)118 void QLabel_minimumSizeHint(QLabelH handle, PSize retval)
119 {
120 	*(QSize *)retval = ((QLabel *)handle)->minimumSizeHint();
121 }
122 
QLabel_setBuddy(QLabelH handle,QWidgetH AnonParam1)123 void QLabel_setBuddy(QLabelH handle, QWidgetH AnonParam1)
124 {
125 	((QLabel *)handle)->setBuddy((QWidget*)AnonParam1);
126 }
127 
QLabel_buddy(QLabelH handle)128 QWidgetH QLabel_buddy(QLabelH handle)
129 {
130 	return (QWidgetH) ((QLabel *)handle)->buddy();
131 }
132 
QLabel_heightForWidth(QLabelH handle,int AnonParam1)133 int QLabel_heightForWidth(QLabelH handle, int AnonParam1)
134 {
135 	return (int) ((QLabel *)handle)->heightForWidth(AnonParam1);
136 }
137 
QLabel_openExternalLinks(QLabelH handle)138 bool QLabel_openExternalLinks(QLabelH handle)
139 {
140 	return (bool) ((QLabel *)handle)->openExternalLinks();
141 }
142 
QLabel_setOpenExternalLinks(QLabelH handle,bool open)143 void QLabel_setOpenExternalLinks(QLabelH handle, bool open)
144 {
145 	((QLabel *)handle)->setOpenExternalLinks(open);
146 }
147 
QLabel_setTextInteractionFlags(QLabelH handle,unsigned int flags)148 void QLabel_setTextInteractionFlags(QLabelH handle, unsigned int flags)
149 {
150 	((QLabel *)handle)->setTextInteractionFlags((Qt::TextInteractionFlags)flags);
151 }
152 
QLabel_textInteractionFlags(QLabelH handle)153 unsigned int QLabel_textInteractionFlags(QLabelH handle)
154 {
155 	return (unsigned int) ((QLabel *)handle)->textInteractionFlags();
156 }
157 
QLabel_setSelection(QLabelH handle,int AnonParam1,int AnonParam2)158 void QLabel_setSelection(QLabelH handle, int AnonParam1, int AnonParam2)
159 {
160 	((QLabel *)handle)->setSelection(AnonParam1, AnonParam2);
161 }
162 
QLabel_hasSelectedText(QLabelH handle)163 bool QLabel_hasSelectedText(QLabelH handle)
164 {
165 	return (bool) ((QLabel *)handle)->hasSelectedText();
166 }
167 
QLabel_selectedText(QLabelH handle,PWideString retval)168 void QLabel_selectedText(QLabelH handle, PWideString retval)
169 {
170 	QString t_retval;
171 	t_retval = ((QLabel *)handle)->selectedText();
172 	copyQStringToPWideString(t_retval, retval);
173 }
174 
QLabel_selectionStart(QLabelH handle)175 int QLabel_selectionStart(QLabelH handle)
176 {
177 	return (int) ((QLabel *)handle)->selectionStart();
178 }
179 
QLabel_setText(QLabelH handle,PWideString AnonParam1)180 void QLabel_setText(QLabelH handle, PWideString AnonParam1)
181 {
182 	QString t_AnonParam1;
183 	copyPWideStringToQString(AnonParam1, t_AnonParam1);
184 	((QLabel *)handle)->setText(t_AnonParam1);
185 }
186 
QLabel_setPixmap(QLabelH handle,const QPixmapH AnonParam1)187 void QLabel_setPixmap(QLabelH handle, const QPixmapH AnonParam1)
188 {
189 	((QLabel *)handle)->setPixmap(*(const QPixmap*)AnonParam1);
190 }
191 
QLabel_setPicture(QLabelH handle,const QPictureH AnonParam1)192 void QLabel_setPicture(QLabelH handle, const QPictureH AnonParam1)
193 {
194 	((QLabel *)handle)->setPicture(*(const QPicture*)AnonParam1);
195 }
196 
QLabel_setMovie(QLabelH handle,QMovieH movie)197 void QLabel_setMovie(QLabelH handle, QMovieH movie)
198 {
199 	((QLabel *)handle)->setMovie((QMovie*)movie);
200 }
201 
QLabel_setNum(QLabelH handle,int AnonParam1)202 void QLabel_setNum(QLabelH handle, int AnonParam1)
203 {
204 	((QLabel *)handle)->setNum(AnonParam1);
205 }
206 
QLabel_setNum2(QLabelH handle,double AnonParam1)207 void QLabel_setNum2(QLabelH handle, double AnonParam1)
208 {
209 	((QLabel *)handle)->setNum(AnonParam1);
210 }
211 
QLabel_clear(QLabelH handle)212 void QLabel_clear(QLabelH handle)
213 {
214 	((QLabel *)handle)->clear();
215 }
216 
217