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 "qabstractspinbox_c.h"
13 
QAbstractSpinBox_Create(QWidgetH parent)14 QAbstractSpinBoxH QAbstractSpinBox_Create(QWidgetH parent)
15 {
16 	return (QAbstractSpinBoxH) new QAbstractSpinBox((QWidget*)parent);
17 }
18 
QAbstractSpinBox_Destroy(QAbstractSpinBoxH handle)19 void QAbstractSpinBox_Destroy(QAbstractSpinBoxH handle)
20 {
21 	delete (QAbstractSpinBox *)handle;
22 }
23 
QAbstractSpinBox_buttonSymbols(QAbstractSpinBoxH handle)24 QAbstractSpinBox::ButtonSymbols QAbstractSpinBox_buttonSymbols(QAbstractSpinBoxH handle)
25 {
26 	return (QAbstractSpinBox::ButtonSymbols) ((QAbstractSpinBox *)handle)->buttonSymbols();
27 }
28 
QAbstractSpinBox_setButtonSymbols(QAbstractSpinBoxH handle,QAbstractSpinBox::ButtonSymbols bs)29 void QAbstractSpinBox_setButtonSymbols(QAbstractSpinBoxH handle, QAbstractSpinBox::ButtonSymbols bs)
30 {
31 	((QAbstractSpinBox *)handle)->setButtonSymbols(bs);
32 }
33 
QAbstractSpinBox_setCorrectionMode(QAbstractSpinBoxH handle,QAbstractSpinBox::CorrectionMode cm)34 void QAbstractSpinBox_setCorrectionMode(QAbstractSpinBoxH handle, QAbstractSpinBox::CorrectionMode cm)
35 {
36 	((QAbstractSpinBox *)handle)->setCorrectionMode(cm);
37 }
38 
QAbstractSpinBox_correctionMode(QAbstractSpinBoxH handle)39 QAbstractSpinBox::CorrectionMode QAbstractSpinBox_correctionMode(QAbstractSpinBoxH handle)
40 {
41 	return (QAbstractSpinBox::CorrectionMode) ((QAbstractSpinBox *)handle)->correctionMode();
42 }
43 
QAbstractSpinBox_hasAcceptableInput(QAbstractSpinBoxH handle)44 bool QAbstractSpinBox_hasAcceptableInput(QAbstractSpinBoxH handle)
45 {
46 	return (bool) ((QAbstractSpinBox *)handle)->hasAcceptableInput();
47 }
48 
QAbstractSpinBox_text(QAbstractSpinBoxH handle,PWideString retval)49 void QAbstractSpinBox_text(QAbstractSpinBoxH handle, PWideString retval)
50 {
51 	QString t_retval;
52 	t_retval = ((QAbstractSpinBox *)handle)->text();
53 	copyQStringToPWideString(t_retval, retval);
54 }
55 
QAbstractSpinBox_specialValueText(QAbstractSpinBoxH handle,PWideString retval)56 void QAbstractSpinBox_specialValueText(QAbstractSpinBoxH handle, PWideString retval)
57 {
58 	QString t_retval;
59 	t_retval = ((QAbstractSpinBox *)handle)->specialValueText();
60 	copyQStringToPWideString(t_retval, retval);
61 }
62 
QAbstractSpinBox_setSpecialValueText(QAbstractSpinBoxH handle,PWideString txt)63 void QAbstractSpinBox_setSpecialValueText(QAbstractSpinBoxH handle, PWideString txt)
64 {
65 	QString t_txt;
66 	copyPWideStringToQString(txt, t_txt);
67 	((QAbstractSpinBox *)handle)->setSpecialValueText(t_txt);
68 }
69 
QAbstractSpinBox_wrapping(QAbstractSpinBoxH handle)70 bool QAbstractSpinBox_wrapping(QAbstractSpinBoxH handle)
71 {
72 	return (bool) ((QAbstractSpinBox *)handle)->wrapping();
73 }
74 
QAbstractSpinBox_setWrapping(QAbstractSpinBoxH handle,bool w)75 void QAbstractSpinBox_setWrapping(QAbstractSpinBoxH handle, bool w)
76 {
77 	((QAbstractSpinBox *)handle)->setWrapping(w);
78 }
79 
QAbstractSpinBox_setReadOnly(QAbstractSpinBoxH handle,bool r)80 void QAbstractSpinBox_setReadOnly(QAbstractSpinBoxH handle, bool r)
81 {
82 	((QAbstractSpinBox *)handle)->setReadOnly(r);
83 }
84 
QAbstractSpinBox_isReadOnly(QAbstractSpinBoxH handle)85 bool QAbstractSpinBox_isReadOnly(QAbstractSpinBoxH handle)
86 {
87 	return (bool) ((QAbstractSpinBox *)handle)->isReadOnly();
88 }
89 
QAbstractSpinBox_setKeyboardTracking(QAbstractSpinBoxH handle,bool kt)90 void QAbstractSpinBox_setKeyboardTracking(QAbstractSpinBoxH handle, bool kt)
91 {
92 	((QAbstractSpinBox *)handle)->setKeyboardTracking(kt);
93 }
94 
QAbstractSpinBox_keyboardTracking(QAbstractSpinBoxH handle)95 bool QAbstractSpinBox_keyboardTracking(QAbstractSpinBoxH handle)
96 {
97 	return (bool) ((QAbstractSpinBox *)handle)->keyboardTracking();
98 }
99 
QAbstractSpinBox_setAlignment(QAbstractSpinBoxH handle,unsigned int flag)100 void QAbstractSpinBox_setAlignment(QAbstractSpinBoxH handle, unsigned int flag)
101 {
102 	((QAbstractSpinBox *)handle)->setAlignment((Qt::Alignment)flag);
103 }
104 
QAbstractSpinBox_alignment(QAbstractSpinBoxH handle)105 unsigned int QAbstractSpinBox_alignment(QAbstractSpinBoxH handle)
106 {
107 	return (unsigned int) ((QAbstractSpinBox *)handle)->alignment();
108 }
109 
QAbstractSpinBox_setFrame(QAbstractSpinBoxH handle,bool AnonParam1)110 void QAbstractSpinBox_setFrame(QAbstractSpinBoxH handle, bool AnonParam1)
111 {
112 	((QAbstractSpinBox *)handle)->setFrame(AnonParam1);
113 }
114 
QAbstractSpinBox_hasFrame(QAbstractSpinBoxH handle)115 bool QAbstractSpinBox_hasFrame(QAbstractSpinBoxH handle)
116 {
117 	return (bool) ((QAbstractSpinBox *)handle)->hasFrame();
118 }
119 
QAbstractSpinBox_setAccelerated(QAbstractSpinBoxH handle,bool on)120 void QAbstractSpinBox_setAccelerated(QAbstractSpinBoxH handle, bool on)
121 {
122 	((QAbstractSpinBox *)handle)->setAccelerated(on);
123 }
124 
QAbstractSpinBox_isAccelerated(QAbstractSpinBoxH handle)125 bool QAbstractSpinBox_isAccelerated(QAbstractSpinBoxH handle)
126 {
127 	return (bool) ((QAbstractSpinBox *)handle)->isAccelerated();
128 }
129 
QAbstractSpinBox_sizeHint(QAbstractSpinBoxH handle,PSize retval)130 void QAbstractSpinBox_sizeHint(QAbstractSpinBoxH handle, PSize retval)
131 {
132 	*(QSize *)retval = ((QAbstractSpinBox *)handle)->sizeHint();
133 }
134 
QAbstractSpinBox_minimumSizeHint(QAbstractSpinBoxH handle,PSize retval)135 void QAbstractSpinBox_minimumSizeHint(QAbstractSpinBoxH handle, PSize retval)
136 {
137 	*(QSize *)retval = ((QAbstractSpinBox *)handle)->minimumSizeHint();
138 }
139 
QAbstractSpinBox_interpretText(QAbstractSpinBoxH handle)140 void QAbstractSpinBox_interpretText(QAbstractSpinBoxH handle)
141 {
142 	((QAbstractSpinBox *)handle)->interpretText();
143 }
144 
QAbstractSpinBox_event(QAbstractSpinBoxH handle,QEventH event)145 bool QAbstractSpinBox_event(QAbstractSpinBoxH handle, QEventH event)
146 {
147 	return (bool) ((QAbstractSpinBox *)handle)->event((QEvent*)event);
148 }
149 
QAbstractSpinBox_inputMethodQuery(QAbstractSpinBoxH handle,QVariantH retval,Qt::InputMethodQuery AnonParam1)150 void QAbstractSpinBox_inputMethodQuery(QAbstractSpinBoxH handle, QVariantH retval, Qt::InputMethodQuery AnonParam1)
151 {
152 	*(QVariant *)retval = ((QAbstractSpinBox *)handle)->inputMethodQuery(AnonParam1);
153 }
154 
QAbstractSpinBox_validate(QAbstractSpinBoxH handle,PWideString input,int * pos)155 QValidator::State QAbstractSpinBox_validate(QAbstractSpinBoxH handle, PWideString input, int* pos)
156 {
157 	QString t_input;
158 	copyPWideStringToQString(input, t_input);
159 	QValidator::State t_retval;
160 	t_retval = (QValidator::State) ((QAbstractSpinBox *)handle)->validate(t_input, *(int*)pos);
161 	copyQStringToPWideString(t_input, input);
162 	return t_retval;
163 }
164 
QAbstractSpinBox_fixup(QAbstractSpinBoxH handle,PWideString input)165 void QAbstractSpinBox_fixup(QAbstractSpinBoxH handle, PWideString input)
166 {
167 	QString t_input;
168 	copyPWideStringToQString(input, t_input);
169 	((QAbstractSpinBox *)handle)->fixup(t_input);
170 	copyQStringToPWideString(t_input, input);
171 }
172 
QAbstractSpinBox_stepBy(QAbstractSpinBoxH handle,int steps)173 void QAbstractSpinBox_stepBy(QAbstractSpinBoxH handle, int steps)
174 {
175 	((QAbstractSpinBox *)handle)->stepBy(steps);
176 }
177 
QAbstractSpinBox_stepUp(QAbstractSpinBoxH handle)178 void QAbstractSpinBox_stepUp(QAbstractSpinBoxH handle)
179 {
180 	((QAbstractSpinBox *)handle)->stepUp();
181 }
182 
QAbstractSpinBox_stepDown(QAbstractSpinBoxH handle)183 void QAbstractSpinBox_stepDown(QAbstractSpinBoxH handle)
184 {
185 	((QAbstractSpinBox *)handle)->stepDown();
186 }
187 
QAbstractSpinBox_selectAll(QAbstractSpinBoxH handle)188 void QAbstractSpinBox_selectAll(QAbstractSpinBoxH handle)
189 {
190 	((QAbstractSpinBox *)handle)->selectAll();
191 }
192 
QAbstractSpinBox_clear(QAbstractSpinBoxH handle)193 void QAbstractSpinBox_clear(QAbstractSpinBoxH handle)
194 {
195 	((QAbstractSpinBox *)handle)->clear();
196 }
197 
198