2024-08-25 04:08:24 +00:00
|
|
|
#include <QByteArray>
|
|
|
|
#include <QColor>
|
|
|
|
#include <QIODevice>
|
|
|
|
#include <QImage>
|
|
|
|
#include <QImageReader>
|
|
|
|
#include <QList>
|
|
|
|
#include <QRect>
|
|
|
|
#include <QSize>
|
|
|
|
#include <QString>
|
2024-08-29 07:01:51 +00:00
|
|
|
#include <QByteArray>
|
|
|
|
#include <cstring>
|
|
|
|
#include "qimagereader.h"
|
|
|
|
#include "gen_qimagereader.h"
|
2024-09-14 22:29:05 +00:00
|
|
|
#include "_cgo_export.h"
|
2024-08-25 04:08:24 +00:00
|
|
|
|
|
|
|
QImageReader* QImageReader_new() {
|
|
|
|
return new QImageReader();
|
|
|
|
}
|
|
|
|
|
|
|
|
QImageReader* QImageReader_new2(QIODevice* device) {
|
|
|
|
return new QImageReader(device);
|
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
QImageReader* QImageReader_new3(struct miqt_string* fileName) {
|
|
|
|
QString fileName_QString = QString::fromUtf8(&fileName->data, fileName->len);
|
2024-08-25 04:08:24 +00:00
|
|
|
return new QImageReader(fileName_QString);
|
|
|
|
}
|
|
|
|
|
|
|
|
QImageReader* QImageReader_new4(QIODevice* device, QByteArray* format) {
|
|
|
|
return new QImageReader(device, *format);
|
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
QImageReader* QImageReader_new5(struct miqt_string* fileName, QByteArray* format) {
|
|
|
|
QString fileName_QString = QString::fromUtf8(&fileName->data, fileName->len);
|
2024-08-25 04:08:24 +00:00
|
|
|
return new QImageReader(fileName_QString, *format);
|
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string* QImageReader_Tr(const char* sourceText) {
|
|
|
|
QString _ret = QImageReader::tr(sourceText);
|
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* QImageReader_TrUtf8(const char* sourceText) {
|
|
|
|
QString _ret = QImageReader::trUtf8(sourceText);
|
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
|
|
|
}
|
|
|
|
|
|
|
|
void QImageReader_SetFormat(QImageReader* self, QByteArray* format) {
|
|
|
|
self->setFormat(*format);
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QByteArray* QImageReader_Format(const QImageReader* self) {
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QByteArray(self->format());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QImageReader_SetAutoDetectImageFormat(QImageReader* self, bool enabled) {
|
|
|
|
self->setAutoDetectImageFormat(enabled);
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
bool QImageReader_AutoDetectImageFormat(const QImageReader* self) {
|
|
|
|
return self->autoDetectImageFormat();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QImageReader_SetDecideFormatFromContent(QImageReader* self, bool ignored) {
|
|
|
|
self->setDecideFormatFromContent(ignored);
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
bool QImageReader_DecideFormatFromContent(const QImageReader* self) {
|
|
|
|
return self->decideFormatFromContent();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QImageReader_SetDevice(QImageReader* self, QIODevice* device) {
|
|
|
|
self->setDevice(device);
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QIODevice* QImageReader_Device(const QImageReader* self) {
|
|
|
|
return self->device();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
void QImageReader_SetFileName(QImageReader* self, struct miqt_string* fileName) {
|
|
|
|
QString fileName_QString = QString::fromUtf8(&fileName->data, fileName->len);
|
2024-08-25 04:08:24 +00:00
|
|
|
self->setFileName(fileName_QString);
|
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string* QImageReader_FileName(const QImageReader* self) {
|
|
|
|
QString _ret = self->fileName();
|
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* QImageReader_Size(const QImageReader* self) {
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QSize(self->size());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-18 00:12:02 +00:00
|
|
|
int QImageReader_ImageFormat(const QImageReader* self) {
|
2024-09-14 22:29:05 +00:00
|
|
|
QImage::Format _ret = self->imageFormat();
|
2024-09-18 00:12:02 +00:00
|
|
|
return static_cast<int>(_ret);
|
2024-08-29 07:01:51 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_array* QImageReader_TextKeys(const QImageReader* self) {
|
|
|
|
QStringList _ret = self->textKeys();
|
2024-09-17 06:29:11 +00:00
|
|
|
// Convert QList<> from C++ memory to manually-managed C memory
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string** _arr = static_cast<struct miqt_string**>(malloc(sizeof(struct miqt_string*) * _ret.length()));
|
|
|
|
for (size_t i = 0, e = _ret.length(); i < e; ++i) {
|
|
|
|
QString _lv_ret = _ret[i];
|
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 _lv_b = _lv_ret.toUtf8();
|
|
|
|
_arr[i] = miqt_strdup(_lv_b.data(), _lv_b.length());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_array* _out = static_cast<struct miqt_array*>(malloc(sizeof(struct miqt_array)));
|
|
|
|
_out->len = _ret.length();
|
|
|
|
_out->data = static_cast<void*>(_arr);
|
|
|
|
return _out;
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string* QImageReader_Text(const QImageReader* self, struct miqt_string* key) {
|
|
|
|
QString key_QString = QString::fromUtf8(&key->data, key->len);
|
|
|
|
QString _ret = self->text(key_QString);
|
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
|
|
|
}
|
|
|
|
|
|
|
|
void QImageReader_SetClipRect(QImageReader* self, QRect* rect) {
|
|
|
|
self->setClipRect(*rect);
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QRect* QImageReader_ClipRect(const QImageReader* self) {
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QRect(self->clipRect());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QImageReader_SetScaledSize(QImageReader* self, QSize* size) {
|
|
|
|
self->setScaledSize(*size);
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QSize* QImageReader_ScaledSize(const QImageReader* self) {
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QSize(self->scaledSize());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QImageReader_SetQuality(QImageReader* self, int quality) {
|
|
|
|
self->setQuality(static_cast<int>(quality));
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
int QImageReader_Quality(const QImageReader* self) {
|
|
|
|
return self->quality();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QImageReader_SetScaledClipRect(QImageReader* self, QRect* rect) {
|
|
|
|
self->setScaledClipRect(*rect);
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QRect* QImageReader_ScaledClipRect(const QImageReader* self) {
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QRect(self->scaledClipRect());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QImageReader_SetBackgroundColor(QImageReader* self, QColor* color) {
|
|
|
|
self->setBackgroundColor(*color);
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QColor* QImageReader_BackgroundColor(const QImageReader* self) {
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QColor(self->backgroundColor());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
bool QImageReader_SupportsAnimation(const QImageReader* self) {
|
|
|
|
return self->supportsAnimation();
|
2024-08-29 07:01:51 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
int QImageReader_Transformation(const QImageReader* self) {
|
2024-09-14 22:29:05 +00:00
|
|
|
QImageIOHandler::Transformations _ret = self->transformation();
|
|
|
|
return static_cast<int>(_ret);
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QImageReader_SetAutoTransform(QImageReader* self, bool enabled) {
|
|
|
|
self->setAutoTransform(enabled);
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
bool QImageReader_AutoTransform(const QImageReader* self) {
|
|
|
|
return self->autoTransform();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void QImageReader_SetGamma(QImageReader* self, float gamma) {
|
|
|
|
self->setGamma(static_cast<float>(gamma));
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
float QImageReader_Gamma(const QImageReader* self) {
|
|
|
|
return self->gamma();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QByteArray* QImageReader_SubType(const QImageReader* self) {
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QByteArray(self->subType());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_array* QImageReader_SupportedSubTypes(const QImageReader* self) {
|
|
|
|
QList<QByteArray> _ret = self->supportedSubTypes();
|
2024-09-17 06:29:11 +00:00
|
|
|
// Convert QList<> from C++ memory to manually-managed C memory
|
|
|
|
QByteArray** _arr = static_cast<QByteArray**>(malloc(sizeof(QByteArray*) * _ret.length()));
|
2024-09-14 22:29:05 +00:00
|
|
|
for (size_t i = 0, e = _ret.length(); i < e; ++i) {
|
|
|
|
_arr[i] = new QByteArray(_ret[i]);
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_array* _out = static_cast<struct miqt_array*>(malloc(sizeof(struct miqt_array)));
|
|
|
|
_out->len = _ret.length();
|
|
|
|
_out->data = static_cast<void*>(_arr);
|
|
|
|
return _out;
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
bool QImageReader_CanRead(const QImageReader* self) {
|
|
|
|
return self->canRead();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
QImage* QImageReader_Read(QImageReader* self) {
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QImage(self->read());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
bool QImageReader_ReadWithImage(QImageReader* self, QImage* image) {
|
|
|
|
return self->read(image);
|
|
|
|
}
|
|
|
|
|
|
|
|
bool QImageReader_JumpToNextImage(QImageReader* self) {
|
|
|
|
return self->jumpToNextImage();
|
|
|
|
}
|
|
|
|
|
|
|
|
bool QImageReader_JumpToImage(QImageReader* self, int imageNumber) {
|
|
|
|
return self->jumpToImage(static_cast<int>(imageNumber));
|
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
int QImageReader_LoopCount(const QImageReader* self) {
|
|
|
|
return self->loopCount();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
int QImageReader_ImageCount(const QImageReader* self) {
|
|
|
|
return self->imageCount();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
int QImageReader_NextImageDelay(const QImageReader* self) {
|
|
|
|
return self->nextImageDelay();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
int QImageReader_CurrentImageNumber(const QImageReader* self) {
|
|
|
|
return self->currentImageNumber();
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-11 05:41:09 +00:00
|
|
|
QRect* QImageReader_CurrentImageRect(const QImageReader* self) {
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QRect(self->currentImageRect());
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-18 00:12:02 +00:00
|
|
|
int QImageReader_Error(const QImageReader* self) {
|
2024-09-14 22:29:05 +00:00
|
|
|
QImageReader::ImageReaderError _ret = self->error();
|
2024-09-18 00:12:02 +00:00
|
|
|
return static_cast<int>(_ret);
|
2024-08-29 07:01:51 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string* QImageReader_ErrorString(const QImageReader* self) {
|
|
|
|
QString _ret = self->errorString();
|
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
|
|
|
bool QImageReader_SupportsOption(const QImageReader* self, int option) {
|
2024-09-11 05:41:09 +00:00
|
|
|
return self->supportsOption(static_cast<QImageIOHandler::ImageOption>(option));
|
2024-08-29 07:01:51 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
QByteArray* QImageReader_ImageFormatWithFileName(struct miqt_string* fileName) {
|
|
|
|
QString fileName_QString = QString::fromUtf8(&fileName->data, fileName->len);
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QByteArray(QImageReader::imageFormat(fileName_QString));
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
QByteArray* QImageReader_ImageFormatWithDevice(QIODevice* device) {
|
2024-09-17 06:29:11 +00:00
|
|
|
return new QByteArray(QImageReader::imageFormat(device));
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_array* QImageReader_SupportedImageFormats() {
|
|
|
|
QList<QByteArray> _ret = QImageReader::supportedImageFormats();
|
2024-09-17 06:29:11 +00:00
|
|
|
// Convert QList<> from C++ memory to manually-managed C memory
|
|
|
|
QByteArray** _arr = static_cast<QByteArray**>(malloc(sizeof(QByteArray*) * _ret.length()));
|
2024-09-14 22:29:05 +00:00
|
|
|
for (size_t i = 0, e = _ret.length(); i < e; ++i) {
|
|
|
|
_arr[i] = new QByteArray(_ret[i]);
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_array* _out = static_cast<struct miqt_array*>(malloc(sizeof(struct miqt_array)));
|
|
|
|
_out->len = _ret.length();
|
|
|
|
_out->data = static_cast<void*>(_arr);
|
|
|
|
return _out;
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_array* QImageReader_SupportedMimeTypes() {
|
|
|
|
QList<QByteArray> _ret = QImageReader::supportedMimeTypes();
|
2024-09-17 06:29:11 +00:00
|
|
|
// Convert QList<> from C++ memory to manually-managed C memory
|
|
|
|
QByteArray** _arr = static_cast<QByteArray**>(malloc(sizeof(QByteArray*) * _ret.length()));
|
2024-09-14 22:29:05 +00:00
|
|
|
for (size_t i = 0, e = _ret.length(); i < e; ++i) {
|
|
|
|
_arr[i] = new QByteArray(_ret[i]);
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_array* _out = static_cast<struct miqt_array*>(malloc(sizeof(struct miqt_array)));
|
|
|
|
_out->len = _ret.length();
|
|
|
|
_out->data = static_cast<void*>(_arr);
|
|
|
|
return _out;
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_array* QImageReader_ImageFormatsForMimeType(QByteArray* mimeType) {
|
|
|
|
QList<QByteArray> _ret = QImageReader::imageFormatsForMimeType(*mimeType);
|
2024-09-17 06:29:11 +00:00
|
|
|
// Convert QList<> from C++ memory to manually-managed C memory
|
|
|
|
QByteArray** _arr = static_cast<QByteArray**>(malloc(sizeof(QByteArray*) * _ret.length()));
|
2024-09-14 22:29:05 +00:00
|
|
|
for (size_t i = 0, e = _ret.length(); i < e; ++i) {
|
|
|
|
_arr[i] = new QByteArray(_ret[i]);
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_array* _out = static_cast<struct miqt_array*>(malloc(sizeof(struct miqt_array)));
|
|
|
|
_out->len = _ret.length();
|
|
|
|
_out->data = static_cast<void*>(_arr);
|
|
|
|
return _out;
|
2024-08-25 04:08:24 +00:00
|
|
|
}
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string* QImageReader_Tr2(const char* sourceText, const char* disambiguation) {
|
|
|
|
QString _ret = QImageReader::tr(sourceText, disambiguation);
|
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* QImageReader_Tr3(const char* sourceText, const char* disambiguation, int n) {
|
|
|
|
QString _ret = QImageReader::tr(sourceText, disambiguation, 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* QImageReader_TrUtf82(const char* sourceText, const char* disambiguation) {
|
|
|
|
QString _ret = QImageReader::trUtf8(sourceText, disambiguation);
|
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* QImageReader_TrUtf83(const char* sourceText, const char* disambiguation, int n) {
|
|
|
|
QString _ret = QImageReader::trUtf8(sourceText, disambiguation, 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
|
|
|
}
|
|
|
|
|
|
|
|
void QImageReader_Delete(QImageReader* self) {
|
|
|
|
delete self;
|
|
|
|
}
|
|
|
|
|