#include #include #include #include #include #include #include #include #include "gen_qprogressbar.h" #include "_cgo_export.h" QProgressBar* QProgressBar_new() { return new QProgressBar(); } QProgressBar* QProgressBar_new2(QWidget* parent) { return new QProgressBar(parent); } QMetaObject* QProgressBar_MetaObject(const QProgressBar* self) { return (QMetaObject*) self->metaObject(); } void* QProgressBar_Metacast(QProgressBar* self, const char* param1) { return self->qt_metacast(param1); } struct miqt_string QProgressBar_Tr(const char* s) { QString _ret = QProgressBar::tr(s); // Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory QByteArray _b = _ret.toUtf8(); struct miqt_string _ms; _ms.len = _b.length(); _ms.data = static_cast(malloc(_ms.len)); memcpy(_ms.data, _b.data(), _ms.len); return _ms; } int QProgressBar_Minimum(const QProgressBar* self) { return self->minimum(); } int QProgressBar_Maximum(const QProgressBar* self) { return self->maximum(); } int QProgressBar_Value(const QProgressBar* self) { return self->value(); } struct miqt_string QProgressBar_Text(const QProgressBar* self) { QString _ret = self->text(); // Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory QByteArray _b = _ret.toUtf8(); struct miqt_string _ms; _ms.len = _b.length(); _ms.data = static_cast(malloc(_ms.len)); memcpy(_ms.data, _b.data(), _ms.len); return _ms; } void QProgressBar_SetTextVisible(QProgressBar* self, bool visible) { self->setTextVisible(visible); } bool QProgressBar_IsTextVisible(const QProgressBar* self) { return self->isTextVisible(); } int QProgressBar_Alignment(const QProgressBar* self) { Qt::Alignment _ret = self->alignment(); return static_cast(_ret); } void QProgressBar_SetAlignment(QProgressBar* self, int alignment) { self->setAlignment(static_cast(alignment)); } QSize* QProgressBar_SizeHint(const QProgressBar* self) { return new QSize(self->sizeHint()); } QSize* QProgressBar_MinimumSizeHint(const QProgressBar* self) { return new QSize(self->minimumSizeHint()); } int QProgressBar_Orientation(const QProgressBar* self) { Qt::Orientation _ret = self->orientation(); return static_cast(_ret); } void QProgressBar_SetInvertedAppearance(QProgressBar* self, bool invert) { self->setInvertedAppearance(invert); } bool QProgressBar_InvertedAppearance(const QProgressBar* self) { return self->invertedAppearance(); } void QProgressBar_SetTextDirection(QProgressBar* self, int textDirection) { self->setTextDirection(static_cast(textDirection)); } int QProgressBar_TextDirection(const QProgressBar* self) { QProgressBar::Direction _ret = self->textDirection(); return static_cast(_ret); } void QProgressBar_SetFormat(QProgressBar* self, struct miqt_string format) { QString format_QString = QString::fromUtf8(format.data, format.len); self->setFormat(format_QString); } void QProgressBar_ResetFormat(QProgressBar* self) { self->resetFormat(); } struct miqt_string QProgressBar_Format(const QProgressBar* self) { QString _ret = self->format(); // Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory QByteArray _b = _ret.toUtf8(); struct miqt_string _ms; _ms.len = _b.length(); _ms.data = static_cast(malloc(_ms.len)); memcpy(_ms.data, _b.data(), _ms.len); return _ms; } void QProgressBar_Reset(QProgressBar* self) { self->reset(); } void QProgressBar_SetRange(QProgressBar* self, int minimum, int maximum) { self->setRange(static_cast(minimum), static_cast(maximum)); } void QProgressBar_SetMinimum(QProgressBar* self, int minimum) { self->setMinimum(static_cast(minimum)); } void QProgressBar_SetMaximum(QProgressBar* self, int maximum) { self->setMaximum(static_cast(maximum)); } void QProgressBar_SetValue(QProgressBar* self, int value) { self->setValue(static_cast(value)); } void QProgressBar_SetOrientation(QProgressBar* self, int orientation) { self->setOrientation(static_cast(orientation)); } void QProgressBar_ValueChanged(QProgressBar* self, int value) { self->valueChanged(static_cast(value)); } void QProgressBar_connect_ValueChanged(QProgressBar* self, intptr_t slot) { QProgressBar::connect(self, static_cast(&QProgressBar::valueChanged), self, [=](int value) { int sigval1 = value; miqt_exec_callback_QProgressBar_ValueChanged(slot, sigval1); }); } struct miqt_string QProgressBar_Tr2(const char* s, const char* c) { QString _ret = QProgressBar::tr(s, c); // Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory QByteArray _b = _ret.toUtf8(); struct miqt_string _ms; _ms.len = _b.length(); _ms.data = static_cast(malloc(_ms.len)); memcpy(_ms.data, _b.data(), _ms.len); return _ms; } struct miqt_string QProgressBar_Tr3(const char* s, const char* c, int n) { QString _ret = QProgressBar::tr(s, c, static_cast(n)); // Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory QByteArray _b = _ret.toUtf8(); struct miqt_string _ms; _ms.len = _b.length(); _ms.data = static_cast(malloc(_ms.len)); memcpy(_ms.data, _b.data(), _ms.len); return _ms; } void QProgressBar_Delete(QProgressBar* self) { delete self; }