/*
 * Interface wrapper code.
 *
 * Generated by SIP 6.6.2
 *
 * Copyright (c) 2022 Riverbank Computing Limited <info@riverbankcomputing.com>
 * 
 * This file is part of PyQt5.
 * 
 * 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 28 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtGui/qpagesize.sip"
#include <qpagesize.h>
#line 29 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQPageSize.cpp"

#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qsize.sip"
#include <qsize.h>
#line 33 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQPageSize.cpp"
#line 27 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qstring.sip"
#include <qstring.h>
#line 36 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQPageSize.cpp"
#line 103 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qsize.sip"
#include <qsize.h>
#line 39 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQPageSize.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qrect.sip"
#include <qrect.h>
#line 42 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQPageSize.cpp"
#line 164 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qrect.sip"
#include <qrect.h>
#line 45 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQPageSize.cpp"


PyDoc_STRVAR(doc_QPageSize_swap, "swap(self, QPageSize)");

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

    {
         ::QPageSize* a0;
         ::QPageSize *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ9", &sipSelf, sipType_QPageSize, &sipCpp, sipType_QPageSize, &a0))
        {
            sipCpp->swap(*a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_swap, doc_QPageSize_swap);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QPageSize_isEquivalentTo, "isEquivalentTo(self, QPageSize) -> bool");

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

    {
        const  ::QPageSize* a0;
        const  ::QPageSize *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ9", &sipSelf, sipType_QPageSize, &sipCpp, sipType_QPageSize, &a0))
        {
            bool sipRes;

            sipRes = sipCpp->isEquivalentTo(*a0);

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_isEquivalentTo, doc_QPageSize_isEquivalentTo);

    return SIP_NULLPTR;
}


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

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

    {
        const  ::QPageSize *sipCpp;

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

            sipRes = sipCpp->isValid();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_isValid, doc_QPageSize_isValid);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QPageSize_key, "key(self) -> str\n"
"key(QPageSize.PageSizeId) -> str");

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

    {
        const  ::QPageSize *sipCpp;

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

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

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

    {
         ::QPageSize::PageSizeId a0;

        if (sipParseArgs(&sipParseErr, sipArgs, "E", sipType_QPageSize_PageSizeId, &a0))
        {
             ::QString*sipRes;

            sipRes = new  ::QString( ::QPageSize::key(a0));

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

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_key, doc_QPageSize_key);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QPageSize_name, "name(self) -> str\n"
"name(QPageSize.PageSizeId) -> str");

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

    {
        const  ::QPageSize *sipCpp;

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

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

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

    {
         ::QPageSize::PageSizeId a0;

        if (sipParseArgs(&sipParseErr, sipArgs, "E", sipType_QPageSize_PageSizeId, &a0))
        {
             ::QString*sipRes;

            sipRes = new  ::QString( ::QPageSize::name(a0));

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

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_name, doc_QPageSize_name);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QPageSize_id, "id(self) -> QPageSize.PageSizeId\n"
"id(QSize, matchPolicy: QPageSize.SizeMatchPolicy = QPageSize.FuzzyMatch) -> QPageSize.PageSizeId\n"
"id(QSizeF, QPageSize.Unit, matchPolicy: QPageSize.SizeMatchPolicy = QPageSize.FuzzyMatch) -> QPageSize.PageSizeId\n"
"id(int) -> QPageSize.PageSizeId");

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

    {
        const  ::QPageSize *sipCpp;

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, SIP_NULLPTR, "B", &sipSelf, sipType_QPageSize, &sipCpp))
        {
             ::QPageSize::PageSizeId sipRes;

            sipRes = sipCpp->id();

            return sipConvertFromEnum(static_cast<int>(sipRes), sipType_QPageSize_PageSizeId);
        }
    }

    {
        const  ::QSize* a0;
         ::QPageSize::SizeMatchPolicy a1 = QPageSize::FuzzyMatch;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "J9|E", sipType_QSize, &a0, sipType_QPageSize_SizeMatchPolicy, &a1))
        {
             ::QPageSize::PageSizeId sipRes;

            sipRes =  ::QPageSize::id(*a0,a1);

            return sipConvertFromEnum(static_cast<int>(sipRes), sipType_QPageSize_PageSizeId);
        }
    }

    {
        const  ::QSizeF* a0;
         ::QPageSize::Unit a1;
         ::QPageSize::SizeMatchPolicy a2 = QPageSize::FuzzyMatch;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "J9E|E", sipType_QSizeF, &a0, sipType_QPageSize_Unit, &a1, sipType_QPageSize_SizeMatchPolicy, &a2))
        {
             ::QPageSize::PageSizeId sipRes;

            sipRes =  ::QPageSize::id(*a0,a1,a2);

            return sipConvertFromEnum(static_cast<int>(sipRes), sipType_QPageSize_PageSizeId);
        }
    }

    {
        int a0;

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, SIP_NULLPTR, "i", &a0))
        {
             ::QPageSize::PageSizeId sipRes;

            sipRes =  ::QPageSize::id(a0);

            return sipConvertFromEnum(static_cast<int>(sipRes), sipType_QPageSize_PageSizeId);
        }
    }

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_id, doc_QPageSize_id);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QPageSize_windowsId, "windowsId(self) -> int\n"
"windowsId(QPageSize.PageSizeId) -> int");

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

    {
        const  ::QPageSize *sipCpp;

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

            sipRes = sipCpp->windowsId();

            return PyLong_FromLong(sipRes);
        }
    }

    {
         ::QPageSize::PageSizeId a0;

        if (sipParseArgs(&sipParseErr, sipArgs, "E", sipType_QPageSize_PageSizeId, &a0))
        {
            int sipRes;

            sipRes =  ::QPageSize::windowsId(a0);

            return PyLong_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_windowsId, doc_QPageSize_windowsId);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QPageSize_definitionSize, "definitionSize(self) -> QSizeF\n"
"definitionSize(QPageSize.PageSizeId) -> QSizeF");

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

    {
        const  ::QPageSize *sipCpp;

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

            sipRes = new  ::QSizeF(sipCpp->definitionSize());

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

    {
         ::QPageSize::PageSizeId a0;

        if (sipParseArgs(&sipParseErr, sipArgs, "E", sipType_QPageSize_PageSizeId, &a0))
        {
             ::QSizeF*sipRes;

            sipRes = new  ::QSizeF( ::QPageSize::definitionSize(a0));

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

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_definitionSize, doc_QPageSize_definitionSize);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QPageSize_definitionUnits, "definitionUnits(self) -> QPageSize.Unit\n"
"definitionUnits(QPageSize.PageSizeId) -> QPageSize.Unit");

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

    {
        const  ::QPageSize *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QPageSize, &sipCpp))
        {
             ::QPageSize::Unit sipRes;

            sipRes = sipCpp->definitionUnits();

            return sipConvertFromEnum(static_cast<int>(sipRes), sipType_QPageSize_Unit);
        }
    }

    {
         ::QPageSize::PageSizeId a0;

        if (sipParseArgs(&sipParseErr, sipArgs, "E", sipType_QPageSize_PageSizeId, &a0))
        {
             ::QPageSize::Unit sipRes;

            sipRes =  ::QPageSize::definitionUnits(a0);

            return sipConvertFromEnum(static_cast<int>(sipRes), sipType_QPageSize_Unit);
        }
    }

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_definitionUnits, doc_QPageSize_definitionUnits);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QPageSize_size, "size(self, QPageSize.Unit) -> QSizeF\n"
"size(QPageSize.PageSizeId, QPageSize.Unit) -> QSizeF");

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

    {
         ::QPageSize::Unit a0;
        const  ::QPageSize *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BE", &sipSelf, sipType_QPageSize, &sipCpp, sipType_QPageSize_Unit, &a0))
        {
             ::QSizeF*sipRes;

            sipRes = new  ::QSizeF(sipCpp->size(a0));

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

    {
         ::QPageSize::PageSizeId a0;
         ::QPageSize::Unit a1;

        if (sipParseArgs(&sipParseErr, sipArgs, "EE", sipType_QPageSize_PageSizeId, &a0, sipType_QPageSize_Unit, &a1))
        {
             ::QSizeF*sipRes;

            sipRes = new  ::QSizeF( ::QPageSize::size(a0,a1));

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

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_size, doc_QPageSize_size);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QPageSize_sizePoints, "sizePoints(self) -> QSize\n"
"sizePoints(QPageSize.PageSizeId) -> QSize");

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

    {
        const  ::QPageSize *sipCpp;

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

            sipRes = new  ::QSize(sipCpp->sizePoints());

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

    {
         ::QPageSize::PageSizeId a0;

        if (sipParseArgs(&sipParseErr, sipArgs, "E", sipType_QPageSize_PageSizeId, &a0))
        {
             ::QSize*sipRes;

            sipRes = new  ::QSize( ::QPageSize::sizePoints(a0));

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

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_sizePoints, doc_QPageSize_sizePoints);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QPageSize_sizePixels, "sizePixels(self, int) -> QSize\n"
"sizePixels(QPageSize.PageSizeId, int) -> QSize");

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

    {
        int a0;
        const  ::QPageSize *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bi", &sipSelf, sipType_QPageSize, &sipCpp, &a0))
        {
             ::QSize*sipRes;

            sipRes = new  ::QSize(sipCpp->sizePixels(a0));

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

    {
         ::QPageSize::PageSizeId a0;
        int a1;

        if (sipParseArgs(&sipParseErr, sipArgs, "Ei", sipType_QPageSize_PageSizeId, &a0, &a1))
        {
             ::QSize*sipRes;

            sipRes = new  ::QSize( ::QPageSize::sizePixels(a0,a1));

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

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_sizePixels, doc_QPageSize_sizePixels);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QPageSize_rect, "rect(self, QPageSize.Unit) -> QRectF");

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

    {
         ::QPageSize::Unit a0;
        const  ::QPageSize *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BE", &sipSelf, sipType_QPageSize, &sipCpp, sipType_QPageSize_Unit, &a0))
        {
             ::QRectF*sipRes;

            sipRes = new  ::QRectF(sipCpp->rect(a0));

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

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_rect, doc_QPageSize_rect);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QPageSize_rectPoints, "rectPoints(self) -> QRect");

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

    {
        const  ::QPageSize *sipCpp;

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

            sipRes = new  ::QRect(sipCpp->rectPoints());

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

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_rectPoints, doc_QPageSize_rectPoints);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QPageSize_rectPixels, "rectPixels(self, int) -> QRect");

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

    {
        int a0;
        const  ::QPageSize *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bi", &sipSelf, sipType_QPageSize, &sipCpp, &a0))
        {
             ::QRect*sipRes;

            sipRes = new  ::QRect(sipCpp->rectPixels(a0));

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

    sipNoMethod(sipParseErr, sipName_QPageSize, sipName_rectPixels, doc_QPageSize_rectPixels);

    return SIP_NULLPTR;
}


extern "C" {static PyObject *slot_QPageSize___eq__(PyObject *,PyObject *);}
static PyObject *slot_QPageSize___eq__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QPageSize *sipCpp = reinterpret_cast< ::QPageSize *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QPageSize));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QPageSize* a0;

        if (sipParseArgs(&sipParseErr, sipArg, "1J9", sipType_QPageSize, &a0))
        {
            bool sipRes;

            sipRes = operator==((*sipCpp), *a0);

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    return sipPySlotExtend(&sipModuleAPI_QtGui, eq_slot, sipType_QPageSize, sipSelf, sipArg);
}


extern "C" {static PyObject *slot_QPageSize___ne__(PyObject *,PyObject *);}
static PyObject *slot_QPageSize___ne__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QPageSize *sipCpp = reinterpret_cast< ::QPageSize *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QPageSize));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QPageSize* a0;

        if (sipParseArgs(&sipParseErr, sipArg, "1J9", sipType_QPageSize, &a0))
        {
            bool sipRes;

            sipRes = operator!=((*sipCpp), *a0);

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    return sipPySlotExtend(&sipModuleAPI_QtGui, ne_slot, sipType_QPageSize, sipSelf, sipArg);
}


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


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


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


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


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


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


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

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

            return sipCpp;
        }
    }

    {
         ::QPageSize::PageSizeId a0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, "E", sipType_QPageSize_PageSizeId, &a0))
        {
            sipCpp = new  ::QPageSize(a0);

            return sipCpp;
        }
    }

    {
        const  ::QSize* a0;
        const  ::QString& a1def = QString();
        const  ::QString* a1 = &a1def;
        int a1State = 0;
         ::QPageSize::SizeMatchPolicy a2 = QPageSize::FuzzyMatch;

        static const char *sipKwdList[] = {
            SIP_NULLPTR,
            sipName_name,
            sipName_matchPolicy,
        };

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, sipKwdList, sipUnused, "J9|J1E", sipType_QSize, &a0, sipType_QString, &a1, &a1State, sipType_QPageSize_SizeMatchPolicy, &a2))
        {
            sipCpp = new  ::QPageSize(*a0,*a1,a2);
            sipReleaseType(const_cast< ::QString *>(a1), sipType_QString, a1State);

            return sipCpp;
        }
    }

    {
        const  ::QSizeF* a0;
         ::QPageSize::Unit a1;
        const  ::QString& a2def = QString();
        const  ::QString* a2 = &a2def;
        int a2State = 0;
         ::QPageSize::SizeMatchPolicy a3 = QPageSize::FuzzyMatch;

        static const char *sipKwdList[] = {
            SIP_NULLPTR,
            SIP_NULLPTR,
            sipName_name,
            sipName_matchPolicy,
        };

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, sipKwdList, sipUnused, "J9E|J1E", sipType_QSizeF, &a0, sipType_QPageSize_Unit, &a1, sipType_QString, &a2, &a2State, sipType_QPageSize_SizeMatchPolicy, &a3))
        {
            sipCpp = new  ::QPageSize(*a0,a1,*a2,a3);
            sipReleaseType(const_cast< ::QString *>(a2), sipType_QString, a2State);

            return sipCpp;
        }
    }

    {
        const  ::QPageSize* a0;

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

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


/* Define this type's Python slots. */
static sipPySlotDef slots_QPageSize[] = {
    {(void *)slot_QPageSize___eq__, eq_slot},
    {(void *)slot_QPageSize___ne__, ne_slot},
    {0, (sipPySlotType)0}
};


static PyMethodDef methods_QPageSize[] = {
    {sipName_definitionSize, meth_QPageSize_definitionSize, METH_VARARGS, doc_QPageSize_definitionSize},
    {sipName_definitionUnits, meth_QPageSize_definitionUnits, METH_VARARGS, doc_QPageSize_definitionUnits},
    {sipName_id, SIP_MLMETH_CAST(meth_QPageSize_id), METH_VARARGS|METH_KEYWORDS, doc_QPageSize_id},
    {sipName_isEquivalentTo, meth_QPageSize_isEquivalentTo, METH_VARARGS, doc_QPageSize_isEquivalentTo},
    {sipName_isValid, meth_QPageSize_isValid, METH_VARARGS, doc_QPageSize_isValid},
    {sipName_key, meth_QPageSize_key, METH_VARARGS, doc_QPageSize_key},
    {sipName_name, meth_QPageSize_name, METH_VARARGS, doc_QPageSize_name},
    {sipName_rect, meth_QPageSize_rect, METH_VARARGS, doc_QPageSize_rect},
    {sipName_rectPixels, meth_QPageSize_rectPixels, METH_VARARGS, doc_QPageSize_rectPixels},
    {sipName_rectPoints, meth_QPageSize_rectPoints, METH_VARARGS, doc_QPageSize_rectPoints},
    {sipName_size, meth_QPageSize_size, METH_VARARGS, doc_QPageSize_size},
    {sipName_sizePixels, meth_QPageSize_sizePixels, METH_VARARGS, doc_QPageSize_sizePixels},
    {sipName_sizePoints, meth_QPageSize_sizePoints, METH_VARARGS, doc_QPageSize_sizePoints},
    {sipName_swap, meth_QPageSize_swap, METH_VARARGS, doc_QPageSize_swap},
    {sipName_windowsId, meth_QPageSize_windowsId, METH_VARARGS, doc_QPageSize_windowsId}
};

static sipEnumMemberDef enummembers_QPageSize[] = {
    {sipName_A0, static_cast<int>( ::QPageSize::A0), 193},
    {sipName_A1, static_cast<int>( ::QPageSize::A1), 193},
    {sipName_A10, static_cast<int>( ::QPageSize::A10), 193},
    {sipName_A2, static_cast<int>( ::QPageSize::A2), 193},
    {sipName_A3, static_cast<int>( ::QPageSize::A3), 193},
    {sipName_A3Extra, static_cast<int>( ::QPageSize::A3Extra), 193},
    {sipName_A4, static_cast<int>( ::QPageSize::A4), 193},
    {sipName_A4Extra, static_cast<int>( ::QPageSize::A4Extra), 193},
    {sipName_A4Plus, static_cast<int>( ::QPageSize::A4Plus), 193},
    {sipName_A4Small, static_cast<int>( ::QPageSize::A4Small), 193},
    {sipName_A5, static_cast<int>( ::QPageSize::A5), 193},
    {sipName_A5Extra, static_cast<int>( ::QPageSize::A5Extra), 193},
    {sipName_A6, static_cast<int>( ::QPageSize::A6), 193},
    {sipName_A7, static_cast<int>( ::QPageSize::A7), 193},
    {sipName_A8, static_cast<int>( ::QPageSize::A8), 193},
    {sipName_A9, static_cast<int>( ::QPageSize::A9), 193},
    {sipName_AnsiA, static_cast<int>( ::QPageSize::AnsiA), 193},
    {sipName_AnsiB, static_cast<int>( ::QPageSize::AnsiB), 193},
    {sipName_AnsiC, static_cast<int>( ::QPageSize::AnsiC), 193},
    {sipName_AnsiD, static_cast<int>( ::QPageSize::AnsiD), 193},
    {sipName_AnsiE, static_cast<int>( ::QPageSize::AnsiE), 193},
    {sipName_ArchA, static_cast<int>( ::QPageSize::ArchA), 193},
    {sipName_ArchB, static_cast<int>( ::QPageSize::ArchB), 193},
    {sipName_ArchC, static_cast<int>( ::QPageSize::ArchC), 193},
    {sipName_ArchD, static_cast<int>( ::QPageSize::ArchD), 193},
    {sipName_ArchE, static_cast<int>( ::QPageSize::ArchE), 193},
    {sipName_B0, static_cast<int>( ::QPageSize::B0), 193},
    {sipName_B1, static_cast<int>( ::QPageSize::B1), 193},
    {sipName_B10, static_cast<int>( ::QPageSize::B10), 193},
    {sipName_B2, static_cast<int>( ::QPageSize::B2), 193},
    {sipName_B3, static_cast<int>( ::QPageSize::B3), 193},
    {sipName_B4, static_cast<int>( ::QPageSize::B4), 193},
    {sipName_B5, static_cast<int>( ::QPageSize::B5), 193},
    {sipName_B5Extra, static_cast<int>( ::QPageSize::B5Extra), 193},
    {sipName_B6, static_cast<int>( ::QPageSize::B6), 193},
    {sipName_B7, static_cast<int>( ::QPageSize::B7), 193},
    {sipName_B8, static_cast<int>( ::QPageSize::B8), 193},
    {sipName_B9, static_cast<int>( ::QPageSize::B9), 193},
    {sipName_C5E, static_cast<int>( ::QPageSize::C5E), 193},
    {sipName_Cicero, static_cast<int>( ::QPageSize::Cicero), 195},
    {sipName_Comm10E, static_cast<int>( ::QPageSize::Comm10E), 193},
    {sipName_Custom, static_cast<int>( ::QPageSize::Custom), 193},
    {sipName_DLE, static_cast<int>( ::QPageSize::DLE), 193},
    {sipName_Didot, static_cast<int>( ::QPageSize::Didot), 195},
    {sipName_DoublePostcard, static_cast<int>( ::QPageSize::DoublePostcard), 193},
    {sipName_Envelope10, static_cast<int>( ::QPageSize::Envelope10), 193},
    {sipName_Envelope11, static_cast<int>( ::QPageSize::Envelope11), 193},
    {sipName_Envelope12, static_cast<int>( ::QPageSize::Envelope12), 193},
    {sipName_Envelope14, static_cast<int>( ::QPageSize::Envelope14), 193},
    {sipName_Envelope9, static_cast<int>( ::QPageSize::Envelope9), 193},
    {sipName_EnvelopeB4, static_cast<int>( ::QPageSize::EnvelopeB4), 193},
    {sipName_EnvelopeB5, static_cast<int>( ::QPageSize::EnvelopeB5), 193},
    {sipName_EnvelopeB6, static_cast<int>( ::QPageSize::EnvelopeB6), 193},
    {sipName_EnvelopeC0, static_cast<int>( ::QPageSize::EnvelopeC0), 193},
    {sipName_EnvelopeC1, static_cast<int>( ::QPageSize::EnvelopeC1), 193},
    {sipName_EnvelopeC2, static_cast<int>( ::QPageSize::EnvelopeC2), 193},
    {sipName_EnvelopeC3, static_cast<int>( ::QPageSize::EnvelopeC3), 193},
    {sipName_EnvelopeC4, static_cast<int>( ::QPageSize::EnvelopeC4), 193},
    {sipName_EnvelopeC5, static_cast<int>( ::QPageSize::EnvelopeC5), 193},
    {sipName_EnvelopeC6, static_cast<int>( ::QPageSize::EnvelopeC6), 193},
    {sipName_EnvelopeC65, static_cast<int>( ::QPageSize::EnvelopeC65), 193},
    {sipName_EnvelopeC7, static_cast<int>( ::QPageSize::EnvelopeC7), 193},
    {sipName_EnvelopeChou3, static_cast<int>( ::QPageSize::EnvelopeChou3), 193},
    {sipName_EnvelopeChou4, static_cast<int>( ::QPageSize::EnvelopeChou4), 193},
    {sipName_EnvelopeDL, static_cast<int>( ::QPageSize::EnvelopeDL), 193},
    {sipName_EnvelopeInvite, static_cast<int>( ::QPageSize::EnvelopeInvite), 193},
    {sipName_EnvelopeItalian, static_cast<int>( ::QPageSize::EnvelopeItalian), 193},
    {sipName_EnvelopeKaku2, static_cast<int>( ::QPageSize::EnvelopeKaku2), 193},
    {sipName_EnvelopeKaku3, static_cast<int>( ::QPageSize::EnvelopeKaku3), 193},
    {sipName_EnvelopeMonarch, static_cast<int>( ::QPageSize::EnvelopeMonarch), 193},
    {sipName_EnvelopePersonal, static_cast<int>( ::QPageSize::EnvelopePersonal), 193},
    {sipName_EnvelopePrc1, static_cast<int>( ::QPageSize::EnvelopePrc1), 193},
    {sipName_EnvelopePrc10, static_cast<int>( ::QPageSize::EnvelopePrc10), 193},
    {sipName_EnvelopePrc2, static_cast<int>( ::QPageSize::EnvelopePrc2), 193},
    {sipName_EnvelopePrc3, static_cast<int>( ::QPageSize::EnvelopePrc3), 193},
    {sipName_EnvelopePrc4, static_cast<int>( ::QPageSize::EnvelopePrc4), 193},
    {sipName_EnvelopePrc5, static_cast<int>( ::QPageSize::EnvelopePrc5), 193},
    {sipName_EnvelopePrc6, static_cast<int>( ::QPageSize::EnvelopePrc6), 193},
    {sipName_EnvelopePrc7, static_cast<int>( ::QPageSize::EnvelopePrc7), 193},
    {sipName_EnvelopePrc8, static_cast<int>( ::QPageSize::EnvelopePrc8), 193},
    {sipName_EnvelopePrc9, static_cast<int>( ::QPageSize::EnvelopePrc9), 193},
    {sipName_EnvelopeYou4, static_cast<int>( ::QPageSize::EnvelopeYou4), 193},
    {sipName_ExactMatch, static_cast<int>( ::QPageSize::ExactMatch), 194},
    {sipName_Executive, static_cast<int>( ::QPageSize::Executive), 193},
    {sipName_ExecutiveStandard, static_cast<int>( ::QPageSize::ExecutiveStandard), 193},
    {sipName_FanFoldGerman, static_cast<int>( ::QPageSize::FanFoldGerman), 193},
    {sipName_FanFoldGermanLegal, static_cast<int>( ::QPageSize::FanFoldGermanLegal), 193},
    {sipName_FanFoldUS, static_cast<int>( ::QPageSize::FanFoldUS), 193},
    {sipName_Folio, static_cast<int>( ::QPageSize::Folio), 193},
    {sipName_FuzzyMatch, static_cast<int>( ::QPageSize::FuzzyMatch), 194},
    {sipName_FuzzyOrientationMatch, static_cast<int>( ::QPageSize::FuzzyOrientationMatch), 194},
    {sipName_Imperial10x11, static_cast<int>( ::QPageSize::Imperial10x11), 193},
    {sipName_Imperial10x13, static_cast<int>( ::QPageSize::Imperial10x13), 193},
    {sipName_Imperial10x14, static_cast<int>( ::QPageSize::Imperial10x14), 193},
    {sipName_Imperial12x11, static_cast<int>( ::QPageSize::Imperial12x11), 193},
    {sipName_Imperial15x11, static_cast<int>( ::QPageSize::Imperial15x11), 193},
    {sipName_Imperial7x9, static_cast<int>( ::QPageSize::Imperial7x9), 193},
    {sipName_Imperial8x10, static_cast<int>( ::QPageSize::Imperial8x10), 193},
    {sipName_Imperial9x11, static_cast<int>( ::QPageSize::Imperial9x11), 193},
    {sipName_Imperial9x12, static_cast<int>( ::QPageSize::Imperial9x12), 193},
    {sipName_Inch, static_cast<int>( ::QPageSize::Inch), 195},
    {sipName_JisB0, static_cast<int>( ::QPageSize::JisB0), 193},
    {sipName_JisB1, static_cast<int>( ::QPageSize::JisB1), 193},
    {sipName_JisB10, static_cast<int>( ::QPageSize::JisB10), 193},
    {sipName_JisB2, static_cast<int>( ::QPageSize::JisB2), 193},
    {sipName_JisB3, static_cast<int>( ::QPageSize::JisB3), 193},
    {sipName_JisB4, static_cast<int>( ::QPageSize::JisB4), 193},
    {sipName_JisB5, static_cast<int>( ::QPageSize::JisB5), 193},
    {sipName_JisB6, static_cast<int>( ::QPageSize::JisB6), 193},
    {sipName_JisB7, static_cast<int>( ::QPageSize::JisB7), 193},
    {sipName_JisB8, static_cast<int>( ::QPageSize::JisB8), 193},
    {sipName_JisB9, static_cast<int>( ::QPageSize::JisB9), 193},
    {sipName_LastPageSize, static_cast<int>( ::QPageSize::LastPageSize), 193},
    {sipName_Ledger, static_cast<int>( ::QPageSize::Ledger), 193},
    {sipName_Legal, static_cast<int>( ::QPageSize::Legal), 193},
    {sipName_LegalExtra, static_cast<int>( ::QPageSize::LegalExtra), 193},
    {sipName_Letter, static_cast<int>( ::QPageSize::Letter), 193},
    {sipName_LetterExtra, static_cast<int>( ::QPageSize::LetterExtra), 193},
    {sipName_LetterPlus, static_cast<int>( ::QPageSize::LetterPlus), 193},
    {sipName_LetterSmall, static_cast<int>( ::QPageSize::LetterSmall), 193},
    {sipName_Millimeter, static_cast<int>( ::QPageSize::Millimeter), 195},
    {sipName_NPageSize, static_cast<int>( ::QPageSize::NPageSize), 193},
    {sipName_NPaperSize, static_cast<int>( ::QPageSize::NPaperSize), 193},
    {sipName_Note, static_cast<int>( ::QPageSize::Note), 193},
    {sipName_Pica, static_cast<int>( ::QPageSize::Pica), 195},
    {sipName_Point, static_cast<int>( ::QPageSize::Point), 195},
    {sipName_Postcard, static_cast<int>( ::QPageSize::Postcard), 193},
    {sipName_Prc16K, static_cast<int>( ::QPageSize::Prc16K), 193},
    {sipName_Prc32K, static_cast<int>( ::QPageSize::Prc32K), 193},
    {sipName_Prc32KBig, static_cast<int>( ::QPageSize::Prc32KBig), 193},
    {sipName_Quarto, static_cast<int>( ::QPageSize::Quarto), 193},
    {sipName_Statement, static_cast<int>( ::QPageSize::Statement), 193},
    {sipName_SuperA, static_cast<int>( ::QPageSize::SuperA), 193},
    {sipName_SuperB, static_cast<int>( ::QPageSize::SuperB), 193},
    {sipName_Tabloid, static_cast<int>( ::QPageSize::Tabloid), 193},
    {sipName_TabloidExtra, static_cast<int>( ::QPageSize::TabloidExtra), 193},
};

PyDoc_STRVAR(doc_QPageSize, "\1QPageSize()\n"
"QPageSize(QPageSize.PageSizeId)\n"
"QPageSize(QSize, name: str = '', matchPolicy: QPageSize.SizeMatchPolicy = QPageSize.FuzzyMatch)\n"
"QPageSize(QSizeF, QPageSize.Unit, name: str = '', matchPolicy: QPageSize.SizeMatchPolicy = QPageSize.FuzzyMatch)\n"
"QPageSize(QPageSize)");


static pyqt5ClassPluginDef plugin_QPageSize = {
    SIP_NULLPTR,
    0,
    SIP_NULLPTR,
    SIP_NULLPTR
};


sipClassTypeDef sipTypeDef_QtGui_QPageSize = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QPageSize,
        SIP_NULLPTR,
        &plugin_QPageSize
    },
    {
        sipNameNr_QPageSize,
        {0, 0, 1},
        15, methods_QPageSize,
        136, enummembers_QPageSize,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QPageSize,
    -1,
    sipNameNr_sip_simplewrapper,
    SIP_NULLPTR,
    slots_QPageSize,
    init_type_QPageSize,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QPageSize,
    assign_QPageSize,
    array_QPageSize,
    copy_QPageSize,
    release_QPageSize,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    array_delete_QPageSize,
    sizeof ( ::QPageSize),
};
