/*
 * 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 807 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtGui/qevent.sip"
#include <qevent.h>
#line 29 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQScrollPrepareEvent.cpp"

#line 98 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qpoint.sip"
#include <qpoint.h>
#line 33 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQScrollPrepareEvent.cpp"
#line 164 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qrect.sip"
#include <qrect.h>
#line 36 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQScrollPrepareEvent.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/sipQtGuiQScrollPrepareEvent.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 42 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQScrollPrepareEvent.cpp"


class sipQScrollPrepareEvent : public  ::QScrollPrepareEvent
{
public:
    sipQScrollPrepareEvent(const  ::QPointF&);
    sipQScrollPrepareEvent(const  ::QScrollPrepareEvent&);
    ~sipQScrollPrepareEvent();

public:
    sipSimpleWrapper *sipPySelf;

private:
    sipQScrollPrepareEvent(const sipQScrollPrepareEvent &);
    sipQScrollPrepareEvent &operator = (const sipQScrollPrepareEvent &);
};

sipQScrollPrepareEvent::sipQScrollPrepareEvent(const  ::QPointF& a0):  ::QScrollPrepareEvent(a0), sipPySelf(SIP_NULLPTR)
{
}

sipQScrollPrepareEvent::sipQScrollPrepareEvent(const  ::QScrollPrepareEvent& a0):  ::QScrollPrepareEvent(a0), sipPySelf(SIP_NULLPTR)
{
}

sipQScrollPrepareEvent::~sipQScrollPrepareEvent()
{
    sipInstanceDestroyedEx(&sipPySelf);
}


PyDoc_STRVAR(doc_QScrollPrepareEvent_startPos, "startPos(self) -> QPointF");

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

    {
        const  ::QScrollPrepareEvent *sipCpp;

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

            sipRes = new  ::QPointF(sipCpp->startPos());

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

    sipNoMethod(sipParseErr, sipName_QScrollPrepareEvent, sipName_startPos, doc_QScrollPrepareEvent_startPos);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QScrollPrepareEvent_viewportSize, "viewportSize(self) -> QSizeF");

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

    {
        const  ::QScrollPrepareEvent *sipCpp;

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

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

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

    sipNoMethod(sipParseErr, sipName_QScrollPrepareEvent, sipName_viewportSize, doc_QScrollPrepareEvent_viewportSize);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QScrollPrepareEvent_contentPosRange, "contentPosRange(self) -> QRectF");

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

    {
        const  ::QScrollPrepareEvent *sipCpp;

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

            sipRes = new  ::QRectF(sipCpp->contentPosRange());

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

    sipNoMethod(sipParseErr, sipName_QScrollPrepareEvent, sipName_contentPosRange, doc_QScrollPrepareEvent_contentPosRange);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QScrollPrepareEvent_contentPos, "contentPos(self) -> QPointF");

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

    {
        const  ::QScrollPrepareEvent *sipCpp;

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

            sipRes = new  ::QPointF(sipCpp->contentPos());

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

    sipNoMethod(sipParseErr, sipName_QScrollPrepareEvent, sipName_contentPos, doc_QScrollPrepareEvent_contentPos);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QScrollPrepareEvent_setViewportSize, "setViewportSize(self, QSizeF)");

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

    {
        const  ::QSizeF* a0;
         ::QScrollPrepareEvent *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ9", &sipSelf, sipType_QScrollPrepareEvent, &sipCpp, sipType_QSizeF, &a0))
        {
            sipCpp->setViewportSize(*a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QScrollPrepareEvent, sipName_setViewportSize, doc_QScrollPrepareEvent_setViewportSize);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QScrollPrepareEvent_setContentPosRange, "setContentPosRange(self, QRectF)");

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

    {
        const  ::QRectF* a0;
         ::QScrollPrepareEvent *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ9", &sipSelf, sipType_QScrollPrepareEvent, &sipCpp, sipType_QRectF, &a0))
        {
            sipCpp->setContentPosRange(*a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QScrollPrepareEvent, sipName_setContentPosRange, doc_QScrollPrepareEvent_setContentPosRange);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QScrollPrepareEvent_setContentPos, "setContentPos(self, Union[QPointF, QPoint])");

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

    {
        const  ::QPointF* a0;
        int a0State = 0;
         ::QScrollPrepareEvent *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QScrollPrepareEvent, &sipCpp, sipType_QPointF, &a0, &a0State))
        {
            sipCpp->setContentPos(*a0);
            sipReleaseType(const_cast< ::QPointF *>(a0), sipType_QPointF, a0State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QScrollPrepareEvent, sipName_setContentPos, doc_QScrollPrepareEvent_setContentPos);

    return SIP_NULLPTR;
}


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

    if (targetType == sipType_QScrollPrepareEvent)
        return sipCppV;

    if (targetType == sipType_QEvent)
        return static_cast< ::QEvent *>(sipCpp);

    return SIP_NULLPTR;
}


/* Call the instance's destructor. */
extern "C" {static void release_QScrollPrepareEvent(void *, int);}
static void release_QScrollPrepareEvent(void *sipCppV, int sipState)
{
    if (sipState & SIP_DERIVED_CLASS)
        delete reinterpret_cast<sipQScrollPrepareEvent *>(sipCppV);
    else
        delete reinterpret_cast< ::QScrollPrepareEvent *>(sipCppV);
}


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


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


extern "C" {static void dealloc_QScrollPrepareEvent(sipSimpleWrapper *);}
static void dealloc_QScrollPrepareEvent(sipSimpleWrapper *sipSelf)
{
    if (sipIsDerivedClass(sipSelf))
        reinterpret_cast<sipQScrollPrepareEvent *>(sipGetAddress(sipSelf))->sipPySelf = SIP_NULLPTR;

    if (sipIsOwnedByPython(sipSelf))
    {
        release_QScrollPrepareEvent(sipGetAddress(sipSelf), sipIsDerivedClass(sipSelf));
    }
}


extern "C" {static void *init_type_QScrollPrepareEvent(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_type_QScrollPrepareEvent(sipSimpleWrapper *sipSelf, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **, PyObject **sipParseErr)
{
    sipQScrollPrepareEvent *sipCpp = SIP_NULLPTR;

    {
        const  ::QPointF* a0;
        int a0State = 0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, "J1", sipType_QPointF, &a0, &a0State))
        {
            sipCpp = new sipQScrollPrepareEvent(*a0);
            sipReleaseType(const_cast< ::QPointF *>(a0), sipType_QPointF, a0State);

            sipCpp->sipPySelf = sipSelf;

            return sipCpp;
        }
    }

    {
        const  ::QScrollPrepareEvent* a0;

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

            sipCpp->sipPySelf = sipSelf;

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


/* Define this type's super-types. */
static sipEncodedTypeDef supers_QScrollPrepareEvent[] = {{6, 0, 1}};


static PyMethodDef methods_QScrollPrepareEvent[] = {
    {sipName_contentPos, meth_QScrollPrepareEvent_contentPos, METH_VARARGS, doc_QScrollPrepareEvent_contentPos},
    {sipName_contentPosRange, meth_QScrollPrepareEvent_contentPosRange, METH_VARARGS, doc_QScrollPrepareEvent_contentPosRange},
    {sipName_setContentPos, meth_QScrollPrepareEvent_setContentPos, METH_VARARGS, doc_QScrollPrepareEvent_setContentPos},
    {sipName_setContentPosRange, meth_QScrollPrepareEvent_setContentPosRange, METH_VARARGS, doc_QScrollPrepareEvent_setContentPosRange},
    {sipName_setViewportSize, meth_QScrollPrepareEvent_setViewportSize, METH_VARARGS, doc_QScrollPrepareEvent_setViewportSize},
    {sipName_startPos, meth_QScrollPrepareEvent_startPos, METH_VARARGS, doc_QScrollPrepareEvent_startPos},
    {sipName_viewportSize, meth_QScrollPrepareEvent_viewportSize, METH_VARARGS, doc_QScrollPrepareEvent_viewportSize}
};

PyDoc_STRVAR(doc_QScrollPrepareEvent, "\1QScrollPrepareEvent(Union[QPointF, QPoint])\n"
"QScrollPrepareEvent(QScrollPrepareEvent)");


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


sipClassTypeDef sipTypeDef_QtGui_QScrollPrepareEvent = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_SCC|SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QScrollPrepareEvent,
        SIP_NULLPTR,
        &plugin_QScrollPrepareEvent
    },
    {
        sipNameNr_QScrollPrepareEvent,
        {0, 0, 1},
        7, methods_QScrollPrepareEvent,
        0, SIP_NULLPTR,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QScrollPrepareEvent,
    -1,
    -1,
    supers_QScrollPrepareEvent,
    SIP_NULLPTR,
    init_type_QScrollPrepareEvent,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QScrollPrepareEvent,
    assign_QScrollPrepareEvent,
    SIP_NULLPTR,
    copy_QScrollPrepareEvent,
    release_QScrollPrepareEvent,
    cast_QScrollPrepareEvent,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    sizeof ( ::QScrollPrepareEvent),
};
