2024-08-25 04:08:24 +00:00
|
|
|
#include <QFormLayout>
|
2024-08-29 07:01:51 +00:00
|
|
|
#define WORKAROUND_INNER_CLASS_DEFINITION_QFormLayout__TakeRowResult
|
2024-08-25 04:08:24 +00:00
|
|
|
#include <QLayout>
|
|
|
|
#include <QLayoutItem>
|
|
|
|
#include <QMetaObject>
|
|
|
|
#include <QRect>
|
|
|
|
#include <QSize>
|
|
|
|
#include <QString>
|
2024-08-29 07:01:51 +00:00
|
|
|
#include <QByteArray>
|
|
|
|
#include <cstring>
|
2024-08-25 04:08:24 +00:00
|
|
|
#include <QWidget>
|
2024-08-29 07:01:51 +00:00
|
|
|
#include "qformlayout.h"
|
2024-08-25 04:08:24 +00:00
|
|
|
|
2024-08-29 07:01:51 +00:00
|
|
|
#include "gen_qformlayout.h"
|
2024-08-25 04:08:24 +00:00
|
|
|
|
|
|
|
extern "C" {
|
|
|
|
extern void miqt_exec_callback(void* cb, int argc, void* argv);
|
|
|
|
}
|
|
|
|
|
|
|
|
QFormLayout* QFormLayout_new() {
|
|
|
|
return new QFormLayout();
|
|
|
|
}
|
|
|
|
|
|
|
|
QFormLayout* QFormLayout_new2(QWidget* parent) {
|
|
|
|
return new QFormLayout(parent);
|
|
|
|
}
|
|
|
|
|
|
|
|
QMetaObject* QFormLayout_MetaObject(QFormLayout* self) {
|
2024-08-29 07:01:51 +00:00
|
|
|
return (QMetaObject*) const_cast<const QFormLayout*>(self)->metaObject();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-08-29 07:01:51 +00:00
|
|
|
void QFormLayout_Tr(const char* s, char** _out, int* _out_Strlen) {
|
2024-08-25 04:08:24 +00:00
|
|
|
QString ret = QFormLayout::tr(s);
|
|
|
|
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
|
|
|
|
QByteArray b = ret.toUtf8();
|
|
|
|
*_out = static_cast<char*>(malloc(b.length()));
|
|
|
|
memcpy(*_out, b.data(), b.length());
|
|
|
|
*_out_Strlen = b.length();
|
|
|
|
}
|
|
|
|
|
2024-08-29 07:01:51 +00:00
|
|
|
void QFormLayout_TrUtf8(const char* s, char** _out, int* _out_Strlen) {
|
2024-08-25 04:08:24 +00:00
|
|
|
QString ret = QFormLayout::trUtf8(s);
|
|
|
|
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
|
|
|
|
QByteArray b = ret.toUtf8();
|
|
|
|
*_out = static_cast<char*>(malloc(b.length()));
|
|
|
|
memcpy(*_out, b.data(), b.length());
|
|
|
|
*_out_Strlen = b.length();
|
|
|
|
}
|
|
|
|
|
2024-08-29 07:01:51 +00:00
|
|
|
void QFormLayout_SetFieldGrowthPolicy(QFormLayout* self, uintptr_t policy) {
|
|
|
|
self->setFieldGrowthPolicy(static_cast<QFormLayout::FieldGrowthPolicy>(policy));
|
|
|
|
}
|
|
|
|
|
|
|
|
uintptr_t QFormLayout_FieldGrowthPolicy(QFormLayout* self) {
|
|
|
|
QFormLayout::FieldGrowthPolicy ret = const_cast<const QFormLayout*>(self)->fieldGrowthPolicy();
|
|
|
|
return static_cast<uintptr_t>(ret);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_SetRowWrapPolicy(QFormLayout* self, int policy) {
|
|
|
|
self->setRowWrapPolicy(static_cast<QFormLayout::RowWrapPolicy>(policy));
|
|
|
|
}
|
|
|
|
|
|
|
|
int QFormLayout_RowWrapPolicy(QFormLayout* self) {
|
|
|
|
QFormLayout::RowWrapPolicy ret = const_cast<const QFormLayout*>(self)->rowWrapPolicy();
|
|
|
|
return static_cast<int>(ret);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_SetLabelAlignment(QFormLayout* self, int alignment) {
|
|
|
|
self->setLabelAlignment(static_cast<Qt::Alignment>(alignment));
|
|
|
|
}
|
|
|
|
|
|
|
|
int QFormLayout_LabelAlignment(QFormLayout* self) {
|
|
|
|
Qt::Alignment ret = const_cast<const QFormLayout*>(self)->labelAlignment();
|
|
|
|
return static_cast<int>(ret);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_SetFormAlignment(QFormLayout* self, int alignment) {
|
|
|
|
self->setFormAlignment(static_cast<Qt::Alignment>(alignment));
|
|
|
|
}
|
|
|
|
|
|
|
|
int QFormLayout_FormAlignment(QFormLayout* self) {
|
|
|
|
Qt::Alignment ret = const_cast<const QFormLayout*>(self)->formAlignment();
|
|
|
|
return static_cast<int>(ret);
|
|
|
|
}
|
|
|
|
|
2024-08-25 04:08:24 +00:00
|
|
|
void QFormLayout_SetHorizontalSpacing(QFormLayout* self, int spacing) {
|
|
|
|
self->setHorizontalSpacing(static_cast<int>(spacing));
|
|
|
|
}
|
|
|
|
|
|
|
|
int QFormLayout_HorizontalSpacing(QFormLayout* self) {
|
2024-08-29 07:01:51 +00:00
|
|
|
return const_cast<const QFormLayout*>(self)->horizontalSpacing();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_SetVerticalSpacing(QFormLayout* self, int spacing) {
|
|
|
|
self->setVerticalSpacing(static_cast<int>(spacing));
|
|
|
|
}
|
|
|
|
|
|
|
|
int QFormLayout_VerticalSpacing(QFormLayout* self) {
|
2024-08-29 07:01:51 +00:00
|
|
|
return const_cast<const QFormLayout*>(self)->verticalSpacing();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
int QFormLayout_Spacing(QFormLayout* self) {
|
2024-08-29 07:01:51 +00:00
|
|
|
return const_cast<const QFormLayout*>(self)->spacing();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_SetSpacing(QFormLayout* self, int spacing) {
|
|
|
|
self->setSpacing(static_cast<int>(spacing));
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_AddRow(QFormLayout* self, QWidget* label, QWidget* field) {
|
|
|
|
self->addRow(label, field);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_AddRow2(QFormLayout* self, QWidget* label, QLayout* field) {
|
|
|
|
self->addRow(label, field);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_AddRow3(QFormLayout* self, const char* labelText, size_t labelText_Strlen, QWidget* field) {
|
|
|
|
QString labelText_QString = QString::fromUtf8(labelText, labelText_Strlen);
|
|
|
|
self->addRow(labelText_QString, field);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_AddRow4(QFormLayout* self, const char* labelText, size_t labelText_Strlen, QLayout* field) {
|
|
|
|
QString labelText_QString = QString::fromUtf8(labelText, labelText_Strlen);
|
|
|
|
self->addRow(labelText_QString, field);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_AddRowWithWidget(QFormLayout* self, QWidget* widget) {
|
|
|
|
self->addRow(widget);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_AddRowWithLayout(QFormLayout* self, QLayout* layout) {
|
|
|
|
self->addRow(layout);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_InsertRow(QFormLayout* self, int row, QWidget* label, QWidget* field) {
|
|
|
|
self->insertRow(static_cast<int>(row), label, field);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_InsertRow2(QFormLayout* self, int row, QWidget* label, QLayout* field) {
|
|
|
|
self->insertRow(static_cast<int>(row), label, field);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_InsertRow3(QFormLayout* self, int row, const char* labelText, size_t labelText_Strlen, QWidget* field) {
|
|
|
|
QString labelText_QString = QString::fromUtf8(labelText, labelText_Strlen);
|
|
|
|
self->insertRow(static_cast<int>(row), labelText_QString, field);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_InsertRow4(QFormLayout* self, int row, const char* labelText, size_t labelText_Strlen, QLayout* field) {
|
|
|
|
QString labelText_QString = QString::fromUtf8(labelText, labelText_Strlen);
|
|
|
|
self->insertRow(static_cast<int>(row), labelText_QString, field);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_InsertRow5(QFormLayout* self, int row, QWidget* widget) {
|
|
|
|
self->insertRow(static_cast<int>(row), widget);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_InsertRow6(QFormLayout* self, int row, QLayout* layout) {
|
|
|
|
self->insertRow(static_cast<int>(row), layout);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_RemoveRow(QFormLayout* self, int row) {
|
|
|
|
self->removeRow(static_cast<int>(row));
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_RemoveRowWithWidget(QFormLayout* self, QWidget* widget) {
|
|
|
|
self->removeRow(widget);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_RemoveRowWithLayout(QFormLayout* self, QLayout* layout) {
|
|
|
|
self->removeRow(layout);
|
|
|
|
}
|
|
|
|
|
2024-08-29 07:01:51 +00:00
|
|
|
QFormLayout__TakeRowResult* QFormLayout_TakeRow(QFormLayout* self, int row) {
|
|
|
|
QFormLayout::TakeRowResult ret = self->takeRow(static_cast<int>(row));
|
|
|
|
// Copy-construct value returned type into heap-allocated copy
|
|
|
|
return static_cast<QFormLayout::TakeRowResult*>(new QFormLayout::TakeRowResult(ret));
|
|
|
|
}
|
|
|
|
|
|
|
|
QFormLayout__TakeRowResult* QFormLayout_TakeRowWithWidget(QFormLayout* self, QWidget* widget) {
|
|
|
|
QFormLayout::TakeRowResult ret = self->takeRow(widget);
|
|
|
|
// Copy-construct value returned type into heap-allocated copy
|
|
|
|
return static_cast<QFormLayout::TakeRowResult*>(new QFormLayout::TakeRowResult(ret));
|
|
|
|
}
|
|
|
|
|
|
|
|
QFormLayout__TakeRowResult* QFormLayout_TakeRowWithLayout(QFormLayout* self, QLayout* layout) {
|
|
|
|
QFormLayout::TakeRowResult ret = self->takeRow(layout);
|
|
|
|
// Copy-construct value returned type into heap-allocated copy
|
|
|
|
return static_cast<QFormLayout::TakeRowResult*>(new QFormLayout::TakeRowResult(ret));
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_SetItem(QFormLayout* self, int row, int role, QLayoutItem* item) {
|
|
|
|
self->setItem(static_cast<int>(row), static_cast<QFormLayout::ItemRole>(role), item);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_SetWidget(QFormLayout* self, int row, int role, QWidget* widget) {
|
|
|
|
self->setWidget(static_cast<int>(row), static_cast<QFormLayout::ItemRole>(role), widget);
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_SetLayout(QFormLayout* self, int row, int role, QLayout* layout) {
|
|
|
|
self->setLayout(static_cast<int>(row), static_cast<QFormLayout::ItemRole>(role), layout);
|
|
|
|
}
|
|
|
|
|
|
|
|
QLayoutItem* QFormLayout_ItemAt(QFormLayout* self, int row, int role) {
|
|
|
|
return const_cast<const QFormLayout*>(self)->itemAt(static_cast<int>(row), static_cast<QFormLayout::ItemRole>(role));
|
|
|
|
}
|
|
|
|
|
2024-08-25 04:08:24 +00:00
|
|
|
QWidget* QFormLayout_LabelForField(QFormLayout* self, QWidget* field) {
|
2024-08-29 07:01:51 +00:00
|
|
|
return const_cast<const QFormLayout*>(self)->labelForField(field);
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
QWidget* QFormLayout_LabelForFieldWithField(QFormLayout* self, QLayout* field) {
|
2024-08-29 07:01:51 +00:00
|
|
|
return const_cast<const QFormLayout*>(self)->labelForField(field);
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_AddItem(QFormLayout* self, QLayoutItem* item) {
|
|
|
|
self->addItem(item);
|
|
|
|
}
|
|
|
|
|
2024-08-29 07:01:51 +00:00
|
|
|
QLayoutItem* QFormLayout_ItemAtWithIndex(QFormLayout* self, int index) {
|
|
|
|
return const_cast<const QFormLayout*>(self)->itemAt(static_cast<int>(index));
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
QLayoutItem* QFormLayout_TakeAt(QFormLayout* self, int index) {
|
|
|
|
return self->takeAt(static_cast<int>(index));
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_SetGeometry(QFormLayout* self, QRect* rect) {
|
|
|
|
self->setGeometry(*rect);
|
|
|
|
}
|
|
|
|
|
|
|
|
QSize* QFormLayout_MinimumSize(QFormLayout* self) {
|
2024-08-29 07:01:51 +00:00
|
|
|
QSize ret = const_cast<const QFormLayout*>(self)->minimumSize();
|
2024-08-25 04:08:24 +00:00
|
|
|
// Copy-construct value returned type into heap-allocated copy
|
|
|
|
return static_cast<QSize*>(new QSize(ret));
|
|
|
|
}
|
|
|
|
|
|
|
|
QSize* QFormLayout_SizeHint(QFormLayout* self) {
|
2024-08-29 07:01:51 +00:00
|
|
|
QSize ret = const_cast<const QFormLayout*>(self)->sizeHint();
|
2024-08-25 04:08:24 +00:00
|
|
|
// Copy-construct value returned type into heap-allocated copy
|
|
|
|
return static_cast<QSize*>(new QSize(ret));
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_Invalidate(QFormLayout* self) {
|
|
|
|
self->invalidate();
|
|
|
|
}
|
|
|
|
|
|
|
|
bool QFormLayout_HasHeightForWidth(QFormLayout* self) {
|
2024-08-29 07:01:51 +00:00
|
|
|
return const_cast<const QFormLayout*>(self)->hasHeightForWidth();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
int QFormLayout_HeightForWidth(QFormLayout* self, int width) {
|
2024-08-29 07:01:51 +00:00
|
|
|
return const_cast<const QFormLayout*>(self)->heightForWidth(static_cast<int>(width));
|
|
|
|
}
|
|
|
|
|
|
|
|
int QFormLayout_ExpandingDirections(QFormLayout* self) {
|
|
|
|
Qt::Orientations ret = const_cast<const QFormLayout*>(self)->expandingDirections();
|
|
|
|
return static_cast<int>(ret);
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
int QFormLayout_Count(QFormLayout* self) {
|
2024-08-29 07:01:51 +00:00
|
|
|
return const_cast<const QFormLayout*>(self)->count();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
int QFormLayout_RowCount(QFormLayout* self) {
|
2024-08-29 07:01:51 +00:00
|
|
|
return const_cast<const QFormLayout*>(self)->rowCount();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-08-29 07:01:51 +00:00
|
|
|
void QFormLayout_Tr2(const char* s, const char* c, char** _out, int* _out_Strlen) {
|
2024-08-25 04:08:24 +00:00
|
|
|
QString ret = QFormLayout::tr(s, c);
|
|
|
|
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
|
|
|
|
QByteArray b = ret.toUtf8();
|
|
|
|
*_out = static_cast<char*>(malloc(b.length()));
|
|
|
|
memcpy(*_out, b.data(), b.length());
|
|
|
|
*_out_Strlen = b.length();
|
|
|
|
}
|
|
|
|
|
2024-08-29 07:01:51 +00:00
|
|
|
void QFormLayout_Tr3(const char* s, const char* c, int n, char** _out, int* _out_Strlen) {
|
2024-08-25 04:08:24 +00:00
|
|
|
QString ret = QFormLayout::tr(s, c, static_cast<int>(n));
|
|
|
|
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
|
|
|
|
QByteArray b = ret.toUtf8();
|
|
|
|
*_out = static_cast<char*>(malloc(b.length()));
|
|
|
|
memcpy(*_out, b.data(), b.length());
|
|
|
|
*_out_Strlen = b.length();
|
|
|
|
}
|
|
|
|
|
2024-08-29 07:01:51 +00:00
|
|
|
void QFormLayout_TrUtf82(const char* s, const char* c, char** _out, int* _out_Strlen) {
|
2024-08-25 04:08:24 +00:00
|
|
|
QString ret = QFormLayout::trUtf8(s, c);
|
|
|
|
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
|
|
|
|
QByteArray b = ret.toUtf8();
|
|
|
|
*_out = static_cast<char*>(malloc(b.length()));
|
|
|
|
memcpy(*_out, b.data(), b.length());
|
|
|
|
*_out_Strlen = b.length();
|
|
|
|
}
|
|
|
|
|
2024-08-29 07:01:51 +00:00
|
|
|
void QFormLayout_TrUtf83(const char* s, const char* c, int n, char** _out, int* _out_Strlen) {
|
2024-08-25 04:08:24 +00:00
|
|
|
QString ret = QFormLayout::trUtf8(s, c, static_cast<int>(n));
|
|
|
|
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
|
|
|
|
QByteArray b = ret.toUtf8();
|
|
|
|
*_out = static_cast<char*>(malloc(b.length()));
|
|
|
|
memcpy(*_out, b.data(), b.length());
|
|
|
|
*_out_Strlen = b.length();
|
|
|
|
}
|
|
|
|
|
|
|
|
void QFormLayout_Delete(QFormLayout* self) {
|
|
|
|
delete self;
|
|
|
|
}
|
|
|
|
|
2024-08-29 07:01:51 +00:00
|
|
|
void QFormLayout__TakeRowResult_Delete(QFormLayout__TakeRowResult* self) {
|
|
|
|
delete self;
|
|
|
|
}
|
|
|
|
|