/*
 * Interface wrapper code.
 *
 * Generated by SIP 6.15.3
 *
 * Copyright (c) 2026 Riverbank Computing Limited <info@riverbankcomputing.com>
 * 
 * This file is part of PyQt6.
 * 
 * This file may be used under the terms of the GNU General Public License
 * version 3.0 as published by the Free Software Foundation and appearing in
 * the file LICENSE included in the packaging of this file.  Please review the
 * following information to ensure the GNU General Public License version 3.0
 * requirements will be met: http://www.gnu.org/copyleft/gpl.html.
 * 
 * If you do not wish to use this file under the terms of the GPL version 3.0
 * then you may purchase a commercial license.  For more information contact
 * info@riverbankcomputing.com.
 * 
 * This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
 * WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
 */

#include "sipAPIQtGui.h"

#line 534 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qtextformat.sip"
#include <qtextformat.h>
#line 29 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"

#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qtextformat.sip"
#include <qtextformat.h>
#line 33 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 24 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qstring.sip"
#include <qstring.h>
#line 36 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 143 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qpygui_qmap.sip"
#include <qfont.h>
#include <qmap.h>
#line 40 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qfont.sip"
#include <qfont.h>
#line 267 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qfont.sip"
#include <qfont.h>
#line 45 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 29 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qpygui_qmap.sip"
#include <qfont.h>
#include <qmap.h>
#line 49 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qvariant.sip"
#include <qvariant.h>
#line 52 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qstringlist.sip"
#include <qstringlist.h>
#line 55 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qfont.sip"
#include <qfont.h>
#line 58 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 319 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qtextformat.sip"
#include <qtextformat.h>
#line 61 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qpen.sip"
#include <qpen.h>
#line 64 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qcolor.sip"
#include <qcolor.h>
#line 67 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 89 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qtextformat.sip"
#include <qtextformat.h>
#line 70 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 648 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qtextformat.sip"
#include <qtextformat.h>
#line 73 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qbrush.sip"
#include <qbrush.h>
#line 76 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 154 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qtextstream.sip"
#include <qtextstream.h>
#line 81 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 559 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qtextformat.sip"
#include <qtextformat.h>
#line 84 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 622 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qtextformat.sip"
#include <qtextformat.h>
#line 87 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 496 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qtextformat.sip"
#include <qtextformat.h>
#line 90 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 439 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qtextformat.sip"
#include <qtextformat.h>
#line 93 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 146 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qpycore_qmap.sip"
#include <qmap.h>
#line 96 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"
#line 28 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qpycore_qlist.sip"
#include <qlist.h>
#line 99 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTextImageFormat.cpp"


PyDoc_STRVAR(doc_QTextImageFormat_isValid, "isValid(self) -> bool");

extern "C" {static PyObject *meth_QTextImageFormat_isValid(PyObject *, PyObject *);}
static PyObject *meth_QTextImageFormat_isValid(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const ::QTextImageFormat *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTextImageFormat, &sipCpp))
        {
            bool sipRes;

            sipRes = sipCpp->isValid();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextImageFormat, sipName_isValid, doc_QTextImageFormat_isValid);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextImageFormat_name, "name(self) -> str");

extern "C" {static PyObject *meth_QTextImageFormat_name(PyObject *, PyObject *);}
static PyObject *meth_QTextImageFormat_name(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const ::QTextImageFormat *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTextImageFormat, &sipCpp))
        {
            ::QString*sipRes;

            sipRes = new ::QString(sipCpp->name());

            return sipConvertFromNewType(sipRes, sipType_QString, SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextImageFormat, sipName_name, doc_QTextImageFormat_name);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextImageFormat_width, "width(self) -> float");

extern "C" {static PyObject *meth_QTextImageFormat_width(PyObject *, PyObject *);}
static PyObject *meth_QTextImageFormat_width(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const ::QTextImageFormat *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTextImageFormat, &sipCpp))
        {
            ::qreal sipRes;

            sipRes = sipCpp->width();

            return PyFloat_FromDouble(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextImageFormat, sipName_width, doc_QTextImageFormat_width);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextImageFormat_height, "height(self) -> float");

extern "C" {static PyObject *meth_QTextImageFormat_height(PyObject *, PyObject *);}
static PyObject *meth_QTextImageFormat_height(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const ::QTextImageFormat *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTextImageFormat, &sipCpp))
        {
            ::qreal sipRes;

            sipRes = sipCpp->height();

            return PyFloat_FromDouble(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextImageFormat, sipName_height, doc_QTextImageFormat_height);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextImageFormat_quality, "quality(self) -> int");

extern "C" {static PyObject *meth_QTextImageFormat_quality(PyObject *, PyObject *);}
static PyObject *meth_QTextImageFormat_quality(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const ::QTextImageFormat *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTextImageFormat, &sipCpp))
        {
            int sipRes;

            sipRes = sipCpp->quality();

            return PyLong_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextImageFormat, sipName_quality, doc_QTextImageFormat_quality);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextImageFormat_setName, "setName(self, aname: str|None)");

extern "C" {static PyObject *meth_QTextImageFormat_setName(PyObject *, PyObject *);}
static PyObject *meth_QTextImageFormat_setName(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const ::QString* a0;
        int a0State = 0;
        ::QTextImageFormat *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QTextImageFormat, &sipCpp, sipType_QString, &a0, &a0State))
        {
            sipCpp->setName(*a0);
            sipReleaseType(const_cast< ::QString *>(a0), sipType_QString, a0State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextImageFormat, sipName_setName, doc_QTextImageFormat_setName);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextImageFormat_setWidth, "setWidth(self, awidth: float)");

extern "C" {static PyObject *meth_QTextImageFormat_setWidth(PyObject *, PyObject *);}
static PyObject *meth_QTextImageFormat_setWidth(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        ::qreal a0;
        ::QTextImageFormat *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bd", &sipSelf, sipType_QTextImageFormat, &sipCpp, &a0))
        {
            sipCpp->setWidth(a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextImageFormat, sipName_setWidth, doc_QTextImageFormat_setWidth);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextImageFormat_setHeight, "setHeight(self, aheight: float)");

extern "C" {static PyObject *meth_QTextImageFormat_setHeight(PyObject *, PyObject *);}
static PyObject *meth_QTextImageFormat_setHeight(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        ::qreal a0;
        ::QTextImageFormat *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bd", &sipSelf, sipType_QTextImageFormat, &sipCpp, &a0))
        {
            sipCpp->setHeight(a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextImageFormat, sipName_setHeight, doc_QTextImageFormat_setHeight);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextImageFormat_setQuality, "setQuality(self, quality: int = 100)");

extern "C" {static PyObject *meth_QTextImageFormat_setQuality(PyObject *, PyObject *, PyObject *);}
static PyObject *meth_QTextImageFormat_setQuality(PyObject *sipSelf, PyObject *sipArgs, PyObject *sipKwds)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        int a0 = 100;
        ::QTextImageFormat *sipCpp;

        static const char *sipKwdList[] = {
            sipName_quality,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "B|i", &sipSelf, sipType_QTextImageFormat, &sipCpp, &a0))
        {
            sipCpp->setQuality(a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextImageFormat, sipName_setQuality, doc_QTextImageFormat_setQuality);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextImageFormat_setMaximumWidth, "setMaximumWidth(self, maxWidth: QTextLength)");

extern "C" {static PyObject *meth_QTextImageFormat_setMaximumWidth(PyObject *, PyObject *);}
static PyObject *meth_QTextImageFormat_setMaximumWidth(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        ::QTextLength* a0;
        ::QTextImageFormat *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ9", &sipSelf, sipType_QTextImageFormat, &sipCpp, sipType_QTextLength, &a0))
        {
            sipCpp->setMaximumWidth(*a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextImageFormat, sipName_setMaximumWidth, doc_QTextImageFormat_setMaximumWidth);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextImageFormat_maximumWidth, "maximumWidth(self) -> QTextLength");

extern "C" {static PyObject *meth_QTextImageFormat_maximumWidth(PyObject *, PyObject *);}
static PyObject *meth_QTextImageFormat_maximumWidth(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const ::QTextImageFormat *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTextImageFormat, &sipCpp))
        {
            ::QTextLength*sipRes;

            sipRes = new ::QTextLength(sipCpp->maximumWidth());

            return sipConvertFromNewType(sipRes, sipType_QTextLength, SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextImageFormat, sipName_maximumWidth, doc_QTextImageFormat_maximumWidth);

    return SIP_NULLPTR;
}


/* Cast a pointer to a type somewhere in its inheritance hierarchy. */
extern "C" {static void *cast_QTextImageFormat(void *, const sipTypeDef *);}
static void *cast_QTextImageFormat(void *sipCppV, const sipTypeDef *targetType)
{
    ::QTextImageFormat *sipCpp = reinterpret_cast< ::QTextImageFormat *>(sipCppV);

    if (targetType == sipType_QTextImageFormat)
        return sipCppV;

    sipCppV = ((const sipClassTypeDef *)sipType_QTextCharFormat)->ctd_cast(static_cast< ::QTextCharFormat *>(sipCpp), targetType);
    if (sipCppV)
        return sipCppV;

    return SIP_NULLPTR;
}


/* Call the instance's destructor. */
extern "C" {static void release_QTextImageFormat(void *, int);}
static void release_QTextImageFormat(void *sipCppV, int)
{
    delete reinterpret_cast< ::QTextImageFormat *>(sipCppV);
}


extern "C" {static void *array_QTextImageFormat(Py_ssize_t);}
static void *array_QTextImageFormat(Py_ssize_t sipNrElem)
{
    return new ::QTextImageFormat[sipNrElem];
}


extern "C" {static void array_delete_QTextImageFormat(void *);}
static void array_delete_QTextImageFormat(void *sipCpp)
{
    delete[] reinterpret_cast< ::QTextImageFormat *>(sipCpp);
}


extern "C" {static void assign_QTextImageFormat(void *, Py_ssize_t, void *);}
static void assign_QTextImageFormat(void *sipDst, Py_ssize_t sipDstIdx, void *sipSrc)
{
    reinterpret_cast< ::QTextImageFormat *>(sipDst)[sipDstIdx] = *reinterpret_cast< ::QTextImageFormat *>(sipSrc);
}


extern "C" {static void *copy_QTextImageFormat(const void *, Py_ssize_t);}
static void *copy_QTextImageFormat(const void *sipSrc, Py_ssize_t sipSrcIdx)
{
    return new ::QTextImageFormat(reinterpret_cast<const ::QTextImageFormat *>(sipSrc)[sipSrcIdx]);
}


extern "C" {static void dealloc_QTextImageFormat(sipSimpleWrapper *);}
static void dealloc_QTextImageFormat(sipSimpleWrapper *sipSelf)
{
    if (sipIsOwnedByPython(sipSelf))
    {
        release_QTextImageFormat(sipGetAddress(sipSelf), 0);
    }
}


extern "C" {static void *init_type_QTextImageFormat(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_type_QTextImageFormat(sipSimpleWrapper *, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **, PyObject **sipParseErr)
{
    ::QTextImageFormat *sipCpp = SIP_NULLPTR;

    {
        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, ""))
        {
            sipCpp = new ::QTextImageFormat();

            return sipCpp;
        }
    }

    {
        const ::QTextImageFormat* a0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, "J9", sipType_QTextImageFormat, &a0))
        {
            sipCpp = new ::QTextImageFormat(*a0);

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


/* Define this type's super-types. */
static sipEncodedTypeDef supers_QTextImageFormat[] = {{299, 255, 1}};


static PyMethodDef methods_QTextImageFormat[] = {
    {sipName_height, meth_QTextImageFormat_height, METH_VARARGS, doc_QTextImageFormat_height},
    {sipName_isValid, meth_QTextImageFormat_isValid, METH_VARARGS, doc_QTextImageFormat_isValid},
    {sipName_maximumWidth, meth_QTextImageFormat_maximumWidth, METH_VARARGS, doc_QTextImageFormat_maximumWidth},
    {sipName_name, meth_QTextImageFormat_name, METH_VARARGS, doc_QTextImageFormat_name},
    {sipName_quality, meth_QTextImageFormat_quality, METH_VARARGS, doc_QTextImageFormat_quality},
    {sipName_setHeight, meth_QTextImageFormat_setHeight, METH_VARARGS, doc_QTextImageFormat_setHeight},
    {sipName_setMaximumWidth, meth_QTextImageFormat_setMaximumWidth, METH_VARARGS, doc_QTextImageFormat_setMaximumWidth},
    {sipName_setName, meth_QTextImageFormat_setName, METH_VARARGS, doc_QTextImageFormat_setName},
    {sipName_setQuality, SIP_MLMETH_CAST(meth_QTextImageFormat_setQuality), METH_VARARGS|METH_KEYWORDS, doc_QTextImageFormat_setQuality},
    {sipName_setWidth, meth_QTextImageFormat_setWidth, METH_VARARGS, doc_QTextImageFormat_setWidth},
    {sipName_width, meth_QTextImageFormat_width, METH_VARARGS, doc_QTextImageFormat_width}
};

PyDoc_STRVAR(doc_QTextImageFormat, "\1QTextImageFormat()\n"
"QTextImageFormat(a0: QTextImageFormat)");


sipClassTypeDef sipTypeDef_QtGui_QTextImageFormat = {
    {
        SIP_NULLPTR,
        SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QTextImageFormat,
        SIP_NULLPTR,
        SIP_NULLPTR,
    },
    {
        sipNameNr_QTextImageFormat,
        {0, 0, 1},
        11, methods_QTextImageFormat,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QTextImageFormat,
    -1,
    -1,
    supers_QTextImageFormat,
    SIP_NULLPTR,
    init_type_QTextImageFormat,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QTextImageFormat,
    assign_QTextImageFormat,
    array_QTextImageFormat,
    copy_QTextImageFormat,
    release_QTextImageFormat,
    cast_QTextImageFormat,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    array_delete_QTextImageFormat,
    sizeof (::QTextImageFormat),
};
