9 #ifndef UI_PQCALCULATORWIDGET_H 10 #define UI_PQCALCULATORWIDGET_H 12 #include <QtCore/QVariant> 13 #include <QtWidgets/QApplication> 14 #include <QtWidgets/QHBoxLayout> 15 #include <QtWidgets/QPushButton> 16 #include <QtWidgets/QToolButton> 17 #include <QtWidgets/QVBoxLayout> 18 #include <QtWidgets/QWidget> 71 if (CalculatorWidget->objectName().isEmpty())
72 CalculatorWidget->setObjectName(QString::fromUtf8(
"CalculatorWidget"));
73 CalculatorWidget->resize(339, 209);
74 verticalLayout_7 =
new QVBoxLayout(CalculatorWidget);
75 verticalLayout_7->setSpacing(0);
76 verticalLayout_7->setContentsMargins(0, 0, 0, 0);
77 verticalLayout_7->setObjectName(QString::fromUtf8(
"verticalLayout_7"));
79 Function->setObjectName(QString::fromUtf8(
"Function"));
81 verticalLayout_7->addWidget(Function);
83 horizontalLayout_2 =
new QHBoxLayout();
84 horizontalLayout_2->setObjectName(QString::fromUtf8(
"horizontalLayout_2"));
85 verticalLayout =
new QVBoxLayout();
86 verticalLayout->setObjectName(QString::fromUtf8(
"verticalLayout"));
87 Clear =
new QToolButton(CalculatorWidget);
88 Clear->setObjectName(QString::fromUtf8(
"Clear"));
89 QSizePolicy sizePolicy(QSizePolicy::Preferred, QSizePolicy::Preferred);
90 sizePolicy.setHorizontalStretch(0);
91 sizePolicy.setVerticalStretch(0);
92 sizePolicy.setHeightForWidth(Clear->sizePolicy().hasHeightForWidth());
93 Clear->setSizePolicy(sizePolicy);
94 Clear->setFocusPolicy(Qt::NoFocus);
96 verticalLayout->addWidget(Clear);
98 sin =
new QToolButton(CalculatorWidget);
99 sin->setObjectName(QString::fromUtf8(
"sin"));
100 sizePolicy.setHeightForWidth(sin->sizePolicy().hasHeightForWidth());
101 sin->setSizePolicy(sizePolicy);
102 sin->setFocusPolicy(Qt::NoFocus);
104 verticalLayout->addWidget(sin);
106 asin =
new QToolButton(CalculatorWidget);
107 asin->setObjectName(QString::fromUtf8(
"asin"));
108 sizePolicy.setHeightForWidth(asin->sizePolicy().hasHeightForWidth());
109 asin->setSizePolicy(sizePolicy);
110 asin->setFocusPolicy(Qt::NoFocus);
112 verticalLayout->addWidget(asin);
114 sinh =
new QToolButton(CalculatorWidget);
115 sinh->setObjectName(QString::fromUtf8(
"sinh"));
116 sizePolicy.setHeightForWidth(sinh->sizePolicy().hasHeightForWidth());
117 sinh->setSizePolicy(sizePolicy);
118 sinh->setFocusPolicy(Qt::NoFocus);
120 verticalLayout->addWidget(sinh);
122 dot =
new QToolButton(CalculatorWidget);
123 dot->setObjectName(QString::fromUtf8(
"dot"));
124 sizePolicy.setHeightForWidth(dot->sizePolicy().hasHeightForWidth());
125 dot->setSizePolicy(sizePolicy);
126 dot->setFocusPolicy(Qt::NoFocus);
127 dot->setAutoRaise(
false);
129 verticalLayout->addWidget(dot);
132 horizontalLayout_2->addLayout(verticalLayout);
134 verticalLayout_2 =
new QVBoxLayout();
135 verticalLayout_2->setObjectName(QString::fromUtf8(
"verticalLayout_2"));
136 LeftParentheses =
new QToolButton(CalculatorWidget);
137 LeftParentheses->setObjectName(QString::fromUtf8(
"LeftParentheses"));
138 sizePolicy.setHeightForWidth(LeftParentheses->sizePolicy().hasHeightForWidth());
139 LeftParentheses->setSizePolicy(sizePolicy);
140 LeftParentheses->setFocusPolicy(Qt::NoFocus);
142 verticalLayout_2->addWidget(LeftParentheses);
144 cos =
new QToolButton(CalculatorWidget);
145 cos->setObjectName(QString::fromUtf8(
"cos"));
146 sizePolicy.setHeightForWidth(cos->sizePolicy().hasHeightForWidth());
147 cos->setSizePolicy(sizePolicy);
148 cos->setFocusPolicy(Qt::NoFocus);
150 verticalLayout_2->addWidget(cos);
152 acos =
new QToolButton(CalculatorWidget);
153 acos->setObjectName(QString::fromUtf8(
"acos"));
154 sizePolicy.setHeightForWidth(acos->sizePolicy().hasHeightForWidth());
155 acos->setSizePolicy(sizePolicy);
156 acos->setFocusPolicy(Qt::NoFocus);
158 verticalLayout_2->addWidget(acos);
160 cosh =
new QToolButton(CalculatorWidget);
161 cosh->setObjectName(QString::fromUtf8(
"cosh"));
162 sizePolicy.setHeightForWidth(cosh->sizePolicy().hasHeightForWidth());
163 cosh->setSizePolicy(sizePolicy);
164 cosh->setFocusPolicy(Qt::NoFocus);
166 verticalLayout_2->addWidget(cosh);
168 mag =
new QToolButton(CalculatorWidget);
169 mag->setObjectName(QString::fromUtf8(
"mag"));
170 sizePolicy.setHeightForWidth(mag->sizePolicy().hasHeightForWidth());
171 mag->setSizePolicy(sizePolicy);
172 mag->setFocusPolicy(Qt::NoFocus);
174 verticalLayout_2->addWidget(mag);
177 horizontalLayout_2->addLayout(verticalLayout_2);
179 verticalLayout_3 =
new QVBoxLayout();
180 verticalLayout_3->setObjectName(QString::fromUtf8(
"verticalLayout_3"));
181 RightParentheses =
new QToolButton(CalculatorWidget);
182 RightParentheses->setObjectName(QString::fromUtf8(
"RightParentheses"));
183 sizePolicy.setHeightForWidth(RightParentheses->sizePolicy().hasHeightForWidth());
184 RightParentheses->setSizePolicy(sizePolicy);
185 RightParentheses->setFocusPolicy(Qt::NoFocus);
187 verticalLayout_3->addWidget(RightParentheses);
189 tan =
new QToolButton(CalculatorWidget);
190 tan->setObjectName(QString::fromUtf8(
"tan"));
191 sizePolicy.setHeightForWidth(tan->sizePolicy().hasHeightForWidth());
192 tan->setSizePolicy(sizePolicy);
193 tan->setFocusPolicy(Qt::NoFocus);
195 verticalLayout_3->addWidget(tan);
197 atan =
new QToolButton(CalculatorWidget);
198 atan->setObjectName(QString::fromUtf8(
"atan"));
199 sizePolicy.setHeightForWidth(atan->sizePolicy().hasHeightForWidth());
200 atan->setSizePolicy(sizePolicy);
201 atan->setFocusPolicy(Qt::NoFocus);
203 verticalLayout_3->addWidget(atan);
205 tanh =
new QToolButton(CalculatorWidget);
206 tanh->setObjectName(QString::fromUtf8(
"tanh"));
207 sizePolicy.setHeightForWidth(tanh->sizePolicy().hasHeightForWidth());
208 tanh->setSizePolicy(sizePolicy);
209 tanh->setFocusPolicy(Qt::NoFocus);
211 verticalLayout_3->addWidget(tanh);
213 norm =
new QToolButton(CalculatorWidget);
214 norm->setObjectName(QString::fromUtf8(
"norm"));
215 sizePolicy.setHeightForWidth(norm->sizePolicy().hasHeightForWidth());
216 norm->setSizePolicy(sizePolicy);
217 norm->setFocusPolicy(Qt::NoFocus);
219 verticalLayout_3->addWidget(norm);
222 horizontalLayout_2->addLayout(verticalLayout_3);
224 verticalLayout_4 =
new QVBoxLayout();
225 verticalLayout_4->setObjectName(QString::fromUtf8(
"verticalLayout_4"));
226 iHat =
new QToolButton(CalculatorWidget);
227 iHat->setObjectName(QString::fromUtf8(
"iHat"));
228 sizePolicy.setHeightForWidth(iHat->sizePolicy().hasHeightForWidth());
229 iHat->setSizePolicy(sizePolicy);
230 iHat->setFocusPolicy(Qt::NoFocus);
232 verticalLayout_4->addWidget(iHat);
234 abs =
new QToolButton(CalculatorWidget);
235 abs->setObjectName(QString::fromUtf8(
"abs"));
236 sizePolicy.setHeightForWidth(abs->sizePolicy().hasHeightForWidth());
237 abs->setSizePolicy(sizePolicy);
238 abs->setFocusPolicy(Qt::NoFocus);
240 verticalLayout_4->addWidget(abs);
242 ceil =
new QToolButton(CalculatorWidget);
243 ceil->setObjectName(QString::fromUtf8(
"ceil"));
244 sizePolicy.setHeightForWidth(ceil->sizePolicy().hasHeightForWidth());
245 ceil->setSizePolicy(sizePolicy);
246 ceil->setFocusPolicy(Qt::NoFocus);
248 verticalLayout_4->addWidget(ceil);
250 xy =
new QToolButton(CalculatorWidget);
251 xy->setObjectName(QString::fromUtf8(
"xy"));
252 sizePolicy.setHeightForWidth(xy->sizePolicy().hasHeightForWidth());
253 xy->setSizePolicy(sizePolicy);
254 xy->setFocusPolicy(Qt::NoFocus);
256 verticalLayout_4->addWidget(xy);
258 ln =
new QToolButton(CalculatorWidget);
259 ln->setObjectName(QString::fromUtf8(
"ln"));
260 sizePolicy.setHeightForWidth(ln->sizePolicy().hasHeightForWidth());
261 ln->setSizePolicy(sizePolicy);
262 ln->setFocusPolicy(Qt::NoFocus);
264 verticalLayout_4->addWidget(ln);
267 horizontalLayout_2->addLayout(verticalLayout_4);
269 verticalLayout_5 =
new QVBoxLayout();
270 verticalLayout_5->setObjectName(QString::fromUtf8(
"verticalLayout_5"));
271 jHat =
new QToolButton(CalculatorWidget);
272 jHat->setObjectName(QString::fromUtf8(
"jHat"));
273 sizePolicy.setHeightForWidth(jHat->sizePolicy().hasHeightForWidth());
274 jHat->setSizePolicy(sizePolicy);
275 jHat->setFocusPolicy(Qt::NoFocus);
277 verticalLayout_5->addWidget(jHat);
279 sqrt =
new QToolButton(CalculatorWidget);
280 sqrt->setObjectName(QString::fromUtf8(
"sqrt"));
281 sizePolicy.setHeightForWidth(sqrt->sizePolicy().hasHeightForWidth());
282 sqrt->setSizePolicy(sizePolicy);
283 sqrt->setFocusPolicy(Qt::NoFocus);
285 verticalLayout_5->addWidget(sqrt);
287 floor =
new QToolButton(CalculatorWidget);
288 floor->setObjectName(QString::fromUtf8(
"floor"));
289 sizePolicy.setHeightForWidth(floor->sizePolicy().hasHeightForWidth());
290 floor->setSizePolicy(sizePolicy);
291 floor->setFocusPolicy(Qt::NoFocus);
293 verticalLayout_5->addWidget(floor);
295 exp =
new QToolButton(CalculatorWidget);
296 exp->setObjectName(QString::fromUtf8(
"exp"));
297 sizePolicy.setHeightForWidth(exp->sizePolicy().hasHeightForWidth());
298 exp->setSizePolicy(sizePolicy);
299 exp->setFocusPolicy(Qt::NoFocus);
301 verticalLayout_5->addWidget(exp);
303 log10 =
new QToolButton(CalculatorWidget);
304 log10->setObjectName(QString::fromUtf8(
"log10"));
305 sizePolicy.setHeightForWidth(log10->sizePolicy().hasHeightForWidth());
306 log10->setSizePolicy(sizePolicy);
307 log10->setFocusPolicy(Qt::NoFocus);
309 verticalLayout_5->addWidget(log10);
312 horizontalLayout_2->addLayout(verticalLayout_5);
314 verticalLayout_6 =
new QVBoxLayout();
315 verticalLayout_6->setObjectName(QString::fromUtf8(
"verticalLayout_6"));
316 kHat =
new QToolButton(CalculatorWidget);
317 kHat->setObjectName(QString::fromUtf8(
"kHat"));
318 sizePolicy.setHeightForWidth(kHat->sizePolicy().hasHeightForWidth());
319 kHat->setSizePolicy(sizePolicy);
320 kHat->setFocusPolicy(Qt::NoFocus);
322 verticalLayout_6->addWidget(kHat);
324 Plus =
new QToolButton(CalculatorWidget);
325 Plus->setObjectName(QString::fromUtf8(
"Plus"));
326 sizePolicy.setHeightForWidth(Plus->sizePolicy().hasHeightForWidth());
327 Plus->setSizePolicy(sizePolicy);
328 Plus->setFocusPolicy(Qt::NoFocus);
330 verticalLayout_6->addWidget(Plus);
332 Minus =
new QToolButton(CalculatorWidget);
333 Minus->setObjectName(QString::fromUtf8(
"Minus"));
334 sizePolicy.setHeightForWidth(Minus->sizePolicy().hasHeightForWidth());
335 Minus->setSizePolicy(sizePolicy);
336 Minus->setFocusPolicy(Qt::NoFocus);
338 verticalLayout_6->addWidget(Minus);
340 Multiply =
new QToolButton(CalculatorWidget);
341 Multiply->setObjectName(QString::fromUtf8(
"Multiply"));
342 sizePolicy.setHeightForWidth(Multiply->sizePolicy().hasHeightForWidth());
343 Multiply->setSizePolicy(sizePolicy);
344 Multiply->setFocusPolicy(Qt::NoFocus);
346 verticalLayout_6->addWidget(Multiply);
348 Divide =
new QToolButton(CalculatorWidget);
349 Divide->setObjectName(QString::fromUtf8(
"Divide"));
350 sizePolicy.setHeightForWidth(Divide->sizePolicy().hasHeightForWidth());
351 Divide->setSizePolicy(sizePolicy);
352 Divide->setFocusPolicy(Qt::NoFocus);
354 verticalLayout_6->addWidget(Divide);
357 horizontalLayout_2->addLayout(verticalLayout_6);
360 verticalLayout_7->addLayout(horizontalLayout_2);
362 horizontalLayout =
new QHBoxLayout();
363 horizontalLayout->setObjectName(QString::fromUtf8(
"horizontalLayout"));
364 Scalars =
new QPushButton(CalculatorWidget);
365 Scalars->setObjectName(QString::fromUtf8(
"Scalars"));
366 Scalars->setFocusPolicy(Qt::NoFocus);
368 horizontalLayout->addWidget(Scalars);
370 Vectors =
new QPushButton(CalculatorWidget);
371 Vectors->setObjectName(QString::fromUtf8(
"Vectors"));
372 Vectors->setFocusPolicy(Qt::NoFocus);
374 horizontalLayout->addWidget(Vectors);
377 verticalLayout_7->addLayout(horizontalLayout);
379 verticalLayout_7->setStretch(1, 1);
382 QObject::connect(Clear, SIGNAL(pressed()), Function, SLOT(clear()));
384 QMetaObject::connectSlotsByName(CalculatorWidget);
389 CalculatorWidget->setWindowTitle(QCoreApplication::translate(
"CalculatorWidget",
"Form",
nullptr));
390 Clear->setText(QCoreApplication::translate(
"CalculatorWidget",
"Clear",
nullptr));
391 sin->setText(QCoreApplication::translate(
"CalculatorWidget",
"sin",
nullptr));
392 asin->setText(QCoreApplication::translate(
"CalculatorWidget",
"asin",
nullptr));
393 sinh->setText(QCoreApplication::translate(
"CalculatorWidget",
"sinh",
nullptr));
394 dot->setText(QCoreApplication::translate(
"CalculatorWidget",
"dot",
nullptr));
395 LeftParentheses->setText(QCoreApplication::translate(
"CalculatorWidget",
"(",
nullptr));
396 cos->setText(QCoreApplication::translate(
"CalculatorWidget",
"cos",
nullptr));
397 acos->setText(QCoreApplication::translate(
"CalculatorWidget",
"acos",
nullptr));
398 cosh->setText(QCoreApplication::translate(
"CalculatorWidget",
"cosh",
nullptr));
399 mag->setText(QCoreApplication::translate(
"CalculatorWidget",
"mag",
nullptr));
400 RightParentheses->setText(QCoreApplication::translate(
"CalculatorWidget",
")",
nullptr));
401 tan->setText(QCoreApplication::translate(
"CalculatorWidget",
"tan",
nullptr));
402 atan->setText(QCoreApplication::translate(
"CalculatorWidget",
"atan",
nullptr));
403 tanh->setText(QCoreApplication::translate(
"CalculatorWidget",
"tanh",
nullptr));
404 norm->setText(QCoreApplication::translate(
"CalculatorWidget",
"norm",
nullptr));
405 iHat->setText(QCoreApplication::translate(
"CalculatorWidget",
"iHat",
nullptr));
406 abs->setText(QCoreApplication::translate(
"CalculatorWidget",
"abs",
nullptr));
407 ceil->setText(QCoreApplication::translate(
"CalculatorWidget",
"ceil",
nullptr));
408 xy->setText(QCoreApplication::translate(
"CalculatorWidget",
"x^y",
nullptr));
409 ln->setText(QCoreApplication::translate(
"CalculatorWidget",
"ln",
nullptr));
410 jHat->setText(QCoreApplication::translate(
"CalculatorWidget",
"jHat",
nullptr));
411 sqrt->setText(QCoreApplication::translate(
"CalculatorWidget",
"sqrt",
nullptr));
412 floor->setText(QCoreApplication::translate(
"CalculatorWidget",
"floor",
nullptr));
413 exp->setText(QCoreApplication::translate(
"CalculatorWidget",
"exp",
nullptr));
414 log10->setText(QCoreApplication::translate(
"CalculatorWidget",
"log10",
nullptr));
415 kHat->setText(QCoreApplication::translate(
"CalculatorWidget",
"kHat",
nullptr));
416 Plus->setText(QCoreApplication::translate(
"CalculatorWidget",
"+",
nullptr));
417 Minus->setText(QCoreApplication::translate(
"CalculatorWidget",
"-",
nullptr));
418 Multiply->setText(QCoreApplication::translate(
"CalculatorWidget",
"*",
nullptr));
419 Divide->setText(QCoreApplication::translate(
"CalculatorWidget",
"/",
nullptr));
420 Scalars->setText(QCoreApplication::translate(
"CalculatorWidget",
"Scalars",
nullptr));
421 Vectors->setText(QCoreApplication::translate(
"CalculatorWidget",
"Vectors",
nullptr));
432 #endif // UI_PQCALCULATORWIDGET_H