2024-08-25 04:08:24 +00:00
|
|
|
#include <QMdiArea>
|
|
|
|
#include <QMdiSubWindow>
|
|
|
|
#include <QMenu>
|
|
|
|
#include <QMetaObject>
|
|
|
|
#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 "qmdisubwindow.h"
|
|
|
|
#include "gen_qmdisubwindow.h"
|
2024-09-14 22:29:05 +00:00
|
|
|
#include "_cgo_export.h"
|
2024-08-25 04:08:24 +00:00
|
|
|
|
2024-08-29 07:01:51 +00:00
|
|
|
QMdiSubWindow* QMdiSubWindow_new() {
|
|
|
|
return new QMdiSubWindow();
|
|
|
|
}
|
|
|
|
|
|
|
|
QMdiSubWindow* QMdiSubWindow_new2(QWidget* parent) {
|
|
|
|
return new QMdiSubWindow(parent);
|
|
|
|
}
|
|
|
|
|
|
|
|
QMdiSubWindow* QMdiSubWindow_new3(QWidget* parent, int flags) {
|
|
|
|
return new QMdiSubWindow(parent, static_cast<Qt::WindowFlags>(flags));
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QMetaObject* QMdiSubWindow_MetaObject(const QMdiSubWindow* self) {
|
|
|
|
return (QMetaObject*) self->metaObject();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-20 22:32:57 +00:00
|
|
|
void* QMdiSubWindow_Metacast(QMdiSubWindow* self, const char* param1) {
|
|
|
|
return self->qt_metacast(param1);
|
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string* QMdiSubWindow_Tr(const char* s) {
|
|
|
|
QString _ret = QMdiSubWindow::tr(s);
|
2024-08-25 04:08:24 +00:00
|
|
|
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
|
2024-09-14 22:29:05 +00:00
|
|
|
QByteArray _b = _ret.toUtf8();
|
|
|
|
return miqt_strdup(_b.data(), _b.length());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string* QMdiSubWindow_TrUtf8(const char* s) {
|
|
|
|
QString _ret = QMdiSubWindow::trUtf8(s);
|
2024-08-25 04:08:24 +00:00
|
|
|
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
|
2024-09-14 22:29:05 +00:00
|
|
|
QByteArray _b = _ret.toUtf8();
|
|
|
|
return miqt_strdup(_b.data(), _b.length());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QSize* QMdiSubWindow_SizeHint(const QMdiSubWindow* self) {
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QSize(self->sizeHint());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QSize* QMdiSubWindow_MinimumSizeHint(const QMdiSubWindow* self) {
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QSize(self->minimumSizeHint());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QMdiSubWindow_SetWidget(QMdiSubWindow* self, QWidget* widget) {
|
|
|
|
self->setWidget(widget);
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QWidget* QMdiSubWindow_Widget(const QMdiSubWindow* self) {
|
|
|
|
return self->widget();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QWidget* QMdiSubWindow_MaximizedButtonsWidget(const QMdiSubWindow* self) {
|
|
|
|
return self->maximizedButtonsWidget();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QWidget* QMdiSubWindow_MaximizedSystemMenuIconWidget(const QMdiSubWindow* self) {
|
|
|
|
return self->maximizedSystemMenuIconWidget();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
bool QMdiSubWindow_IsShaded(const QMdiSubWindow* self) {
|
|
|
|
return self->isShaded();
|
2024-08-29 07:01:51 +00:00
|
|
|
}
|
|
|
|
|
2024-09-18 00:12:02 +00:00
|
|
|
void QMdiSubWindow_SetOption(QMdiSubWindow* self, int option) {
|
2024-08-29 07:01:51 +00:00
|
|
|
self->setOption(static_cast<QMdiSubWindow::SubWindowOption>(option));
|
|
|
|
}
|
|
|
|
|
2024-09-18 00:12:02 +00:00
|
|
|
bool QMdiSubWindow_TestOption(const QMdiSubWindow* self, int param1) {
|
2024-09-11 05:41:09 +00:00
|
|
|
return self->testOption(static_cast<QMdiSubWindow::SubWindowOption>(param1));
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QMdiSubWindow_SetKeyboardSingleStep(QMdiSubWindow* self, int step) {
|
|
|
|
self->setKeyboardSingleStep(static_cast<int>(step));
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
int QMdiSubWindow_KeyboardSingleStep(const QMdiSubWindow* self) {
|
|
|
|
return self->keyboardSingleStep();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QMdiSubWindow_SetKeyboardPageStep(QMdiSubWindow* self, int step) {
|
|
|
|
self->setKeyboardPageStep(static_cast<int>(step));
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
int QMdiSubWindow_KeyboardPageStep(const QMdiSubWindow* self) {
|
|
|
|
return self->keyboardPageStep();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QMdiSubWindow_SetSystemMenu(QMdiSubWindow* self, QMenu* systemMenu) {
|
|
|
|
self->setSystemMenu(systemMenu);
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QMenu* QMdiSubWindow_SystemMenu(const QMdiSubWindow* self) {
|
|
|
|
return self->systemMenu();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QMdiArea* QMdiSubWindow_MdiArea(const QMdiSubWindow* self) {
|
|
|
|
return self->mdiArea();
|
2024-08-29 07:01:51 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QMdiSubWindow_WindowStateChanged(QMdiSubWindow* self, int oldState, int newState) {
|
|
|
|
self->windowStateChanged(static_cast<Qt::WindowStates>(oldState), static_cast<Qt::WindowStates>(newState));
|
|
|
|
}
|
|
|
|
|
|
|
|
void QMdiSubWindow_connect_WindowStateChanged(QMdiSubWindow* self, void* slot) {
|
|
|
|
QMdiSubWindow::connect(self, static_cast<void (QMdiSubWindow::*)(Qt::WindowStates, Qt::WindowStates)>(&QMdiSubWindow::windowStateChanged), self, [=](Qt::WindowStates oldState, Qt::WindowStates newState) {
|
2024-09-14 22:29:05 +00:00
|
|
|
Qt::WindowStates oldState_ret = oldState;
|
|
|
|
int sigval1 = static_cast<int>(oldState_ret);
|
|
|
|
Qt::WindowStates newState_ret = newState;
|
|
|
|
int sigval2 = static_cast<int>(newState_ret);
|
|
|
|
miqt_exec_callback_QMdiSubWindow_WindowStateChanged(slot, sigval1, sigval2);
|
2024-08-29 07:01:51 +00:00
|
|
|
});
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QMdiSubWindow_AboutToActivate(QMdiSubWindow* self) {
|
|
|
|
self->aboutToActivate();
|
|
|
|
}
|
|
|
|
|
|
|
|
void QMdiSubWindow_connect_AboutToActivate(QMdiSubWindow* self, void* slot) {
|
|
|
|
QMdiSubWindow::connect(self, static_cast<void (QMdiSubWindow::*)()>(&QMdiSubWindow::aboutToActivate), self, [=]() {
|
2024-09-14 22:29:05 +00:00
|
|
|
miqt_exec_callback_QMdiSubWindow_AboutToActivate(slot);
|
2024-08-25 04:08:24 +00:00
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
void QMdiSubWindow_ShowSystemMenu(QMdiSubWindow* self) {
|
|
|
|
self->showSystemMenu();
|
|
|
|
}
|
|
|
|
|
|
|
|
void QMdiSubWindow_ShowShaded(QMdiSubWindow* self) {
|
|
|
|
self->showShaded();
|
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string* QMdiSubWindow_Tr2(const char* s, const char* c) {
|
|
|
|
QString _ret = QMdiSubWindow::tr(s, c);
|
2024-08-25 04:08:24 +00:00
|
|
|
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
|
2024-09-14 22:29:05 +00:00
|
|
|
QByteArray _b = _ret.toUtf8();
|
|
|
|
return miqt_strdup(_b.data(), _b.length());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string* QMdiSubWindow_Tr3(const char* s, const char* c, int n) {
|
|
|
|
QString _ret = QMdiSubWindow::tr(s, c, static_cast<int>(n));
|
2024-08-25 04:08:24 +00:00
|
|
|
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
|
2024-09-14 22:29:05 +00:00
|
|
|
QByteArray _b = _ret.toUtf8();
|
|
|
|
return miqt_strdup(_b.data(), _b.length());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string* QMdiSubWindow_TrUtf82(const char* s, const char* c) {
|
|
|
|
QString _ret = QMdiSubWindow::trUtf8(s, c);
|
2024-08-25 04:08:24 +00:00
|
|
|
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
|
2024-09-14 22:29:05 +00:00
|
|
|
QByteArray _b = _ret.toUtf8();
|
|
|
|
return miqt_strdup(_b.data(), _b.length());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string* QMdiSubWindow_TrUtf83(const char* s, const char* c, int n) {
|
|
|
|
QString _ret = QMdiSubWindow::trUtf8(s, c, static_cast<int>(n));
|
2024-08-25 04:08:24 +00:00
|
|
|
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
|
2024-09-14 22:29:05 +00:00
|
|
|
QByteArray _b = _ret.toUtf8();
|
|
|
|
return miqt_strdup(_b.data(), _b.length());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-18 00:12:02 +00:00
|
|
|
void QMdiSubWindow_SetOption2(QMdiSubWindow* self, int option, bool on) {
|
2024-08-29 07:01:51 +00:00
|
|
|
self->setOption(static_cast<QMdiSubWindow::SubWindowOption>(option), on);
|
|
|
|
}
|
|
|
|
|
2024-08-25 04:08:24 +00:00
|
|
|
void QMdiSubWindow_Delete(QMdiSubWindow* self) {
|
|
|
|
delete self;
|
|
|
|
}
|
|
|
|
|