static PyObject *meth_tlp_GlAbstractPolygon_setTextureName(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        const std::string * a0;
        int a0State = 0;
        tlp::GlAbstractPolygon *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_tlp_GlAbstractPolygon, &sipCpp, sipType_std_string,&a0, &a0State))
        {
            sipCpp->setTextureName(*a0);
            sipReleaseType(const_cast<std::string *>(a0),sipType_std_string,a0State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_GlAbstractPolygon, sipName_setTextureName, doc_tlp_GlAbstractPolygon_setTextureName);

    return NULL;
}
static PyObject *meth_QDomCharacterData_appendData(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        const QString* a0;
        int a0State = 0;
        QDomCharacterData *sipCpp;

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

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QDomCharacterData, sipName_appendData, doc_QDomCharacterData_appendData);

    return NULL;
}
static PyObject *meth_tlp_GlAbstractPolygon_draw(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;
    bool sipSelfWasArg = (!sipSelf || sipIsDerived((sipSimpleWrapper *)sipSelf));

    {
        float a0;
        tlp::Camera * a1;
        tlp::GlAbstractPolygon *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BfJ8", &sipSelf, sipType_tlp_GlAbstractPolygon, &sipCpp, &a0, sipType_tlp_Camera, &a1))
        {
            (sipSelfWasArg ? sipCpp->tlp::GlAbstractPolygon::draw(a0,a1) : sipCpp->draw(a0,a1));

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_GlAbstractPolygon, sipName_draw, doc_tlp_GlAbstractPolygon_draw);

    return NULL;
}
static PyObject *meth_tlp_GlAbstractPolygon_setPoint(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;
    bool sipSelfWasArg = (!sipSelf || sipIsDerived((sipSimpleWrapper *)sipSelf));

    {
        uint a0;
        const tlp::Coord * a1;
        siptlp_GlAbstractPolygon *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BuJ9", &sipSelf, sipType_tlp_GlAbstractPolygon, &sipCpp, &a0, sipType_tlp_Coord, &a1))
        {
            sipCpp->sipProtectVirt_setPoint(sipSelfWasArg,a0,*a1);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_GlAbstractPolygon, sipName_setPoint, doc_tlp_GlAbstractPolygon_setPoint);

    return NULL;
}
Пример #5
0
static PyObject *meth_QNetworkProxy_setType(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
         ::QNetworkProxy::ProxyType a0;
         ::QNetworkProxy *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BE", &sipSelf, sipType_QNetworkProxy, &sipCpp, sipType_QNetworkProxy_ProxyType, &a0))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->setType(a0);
            Py_END_ALLOW_THREADS

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QNetworkProxy, sipName_setType, doc_QNetworkProxy_setType);

    return NULL;
}
Пример #6
0
static PyObject *meth_QTextOption_setTabs(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        const QList<QTextOption::Tab>* a0;
        int a0State = 0;
        QTextOption *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QTextOption, &sipCpp, sipType_QList_0100QTextOption_Tab,&a0, &a0State))
        {
            sipCpp->setTabs(*a0);
            sipReleaseType(const_cast<QList<QTextOption::Tab> *>(a0),sipType_QList_0100QTextOption_Tab,a0State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QTextOption, sipName_setTabs, doc_QTextOption_setTabs);

    return NULL;
}
Пример #7
0
static PyObject *meth_QTextOption_setFlags(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        QTextOption::Flags* a0;
        int a0State = 0;
        QTextOption *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QTextOption, &sipCpp, sipType_QTextOption_Flags, &a0, &a0State))
        {
            sipCpp->setFlags(*a0);
            sipReleaseType(a0,sipType_QTextOption_Flags,a0State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QTextOption, sipName_setFlags, doc_QTextOption_setFlags);

    return NULL;
}
static PyObject *meth_QXmlStreamAttributes_append(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        const QString* a0;
        int a0State = 0;
        const QString* a1;
        int a1State = 0;
        const QString* a2;
        int a2State = 0;
        QXmlStreamAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1J1J1", &sipSelf, sipType_QXmlStreamAttributes, &sipCpp, sipType_QString,&a0, &a0State, sipType_QString,&a1, &a1State, sipType_QString,&a2, &a2State))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->append(*a0,*a1,*a2);
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast<QString *>(a0),sipType_QString,a0State);
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);
            sipReleaseType(const_cast<QString *>(a2),sipType_QString,a2State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
        const QString* a0;
        int a0State = 0;
        const QString* a1;
        int a1State = 0;
        QXmlStreamAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1J1", &sipSelf, sipType_QXmlStreamAttributes, &sipCpp, sipType_QString,&a0, &a0State, sipType_QString,&a1, &a1State))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->append(*a0,*a1);
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast<QString *>(a0),sipType_QString,a0State);
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
        const QXmlStreamAttribute* a0;
        QXmlStreamAttributes *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ9", &sipSelf, sipType_QXmlStreamAttributes, &sipCpp, sipType_QXmlStreamAttribute, &a0))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->append(*a0);
            Py_END_ALLOW_THREADS

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QXmlStreamAttributes, sipName_append, doc_QXmlStreamAttributes_append);

    return NULL;
}
Пример #9
0
static PyObject *meth_QDomElement_setAttributeNS(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        const QString* a0;
        int a0State = 0;
        const QString* a1;
        int a1State = 0;
        const QString* a2;
        int a2State = 0;
        QDomElement *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1J1J1", &sipSelf, sipType_QDomElement, &sipCpp, sipType_QString,&a0, &a0State, sipType_QString,&a1, &a1State, sipType_QString,&a2, &a2State))
        {
            sipCpp->setAttributeNS(*a0,*a1,*a2);
            sipReleaseType(const_cast<QString *>(a0),sipType_QString,a0State);
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);
            sipReleaseType(const_cast<QString *>(a2),sipType_QString,a2State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
        const QString* a0;
        int a0State = 0;
        const QString* a1;
        int a1State = 0;
        qlonglong a2;
        QDomElement *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1J1n", &sipSelf, sipType_QDomElement, &sipCpp, sipType_QString,&a0, &a0State, sipType_QString,&a1, &a1State, &a2))
        {
            sipCpp->setAttributeNS(*a0,*a1,a2);
            sipReleaseType(const_cast<QString *>(a0),sipType_QString,a0State);
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
        const QString* a0;
        int a0State = 0;
        const QString* a1;
        int a1State = 0;
        qulonglong a2;
        QDomElement *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1J1o", &sipSelf, sipType_QDomElement, &sipCpp, sipType_QString,&a0, &a0State, sipType_QString,&a1, &a1State, &a2))
        {
            sipCpp->setAttributeNS(*a0,*a1,a2);
            sipReleaseType(const_cast<QString *>(a0),sipType_QString,a0State);
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
        const QString* a0;
        int a0State = 0;
        const QString* a1;
        int a1State = 0;
        double a2;
        QDomElement *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1J1Xd", &sipSelf, sipType_QDomElement, &sipCpp, sipType_QString,&a0, &a0State, sipType_QString,&a1, &a1State, &a2))
        {
            sipCpp->setAttributeNS(*a0,*a1,a2);
            sipReleaseType(const_cast<QString *>(a0),sipType_QString,a0State);
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
        const QString* a0;
        int a0State = 0;
        const QString* a1;
        int a1State = 0;
        int a2;
        QDomElement *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1J1i", &sipSelf, sipType_QDomElement, &sipCpp, sipType_QString,&a0, &a0State, sipType_QString,&a1, &a1State, &a2))
        {
            sipCpp->setAttributeNS(*a0,*a1,a2);
            sipReleaseType(const_cast<QString *>(a0),sipType_QString,a0State);
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QDomElement, sipName_setAttributeNS, doc_QDomElement_setAttributeNS);

    return NULL;
}
Пример #10
0
static PyObject *meth_QtWin_extendFrameIntoClientArea(PyObject *, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        QWindow* a0;
        int a1;
        int a2;
        int a3;
        int a4;

        if (sipParseArgs(&sipParseErr, sipArgs, "J8iiii", sipType_QWindow, &a0, &a1, &a2, &a3, &a4))
        {
            QtWin::extendFrameIntoClientArea(a0,a1,a2,a3,a4);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
        QWindow* a0;
        const QMargins* a1;

        if (sipParseArgs(&sipParseErr, sipArgs, "J8J9", sipType_QWindow, &a0, sipType_QMargins, &a1))
        {
            QtWin::extendFrameIntoClientArea(a0,*a1);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
        QWidget* a0;
        const QMargins* a1;

        if (sipParseArgs(&sipParseErr, sipArgs, "J8J9", sipType_QWidget, &a0, sipType_QMargins, &a1))
        {
            QtWin::extendFrameIntoClientArea(a0,*a1);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
        QWidget* a0;
        int a1;
        int a2;
        int a3;
        int a4;

        if (sipParseArgs(&sipParseErr, sipArgs, "J8iiii", sipType_QWidget, &a0, &a1, &a2, &a3, &a4))
        {
            QtWin::extendFrameIntoClientArea(a0,a1,a2,a3,a4);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoFunction(sipParseErr, sipName_extendFrameIntoClientArea, doc_QtWin_extendFrameIntoClientArea);

    return NULL;
}
static PyObject *meth_QSGMaterialShader_attributeNames(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;
    PyObject *sipOrigSelf = sipSelf;

    {
        const QSGMaterialShader *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QSGMaterialShader, &sipCpp))
        {
            PyObject * sipRes = 0;
            int sipIsErr = 0;

            if (!sipOrigSelf)
            {
                sipAbstractMethod(sipName_QSGMaterialShader, sipName_attributeNames);
                return NULL;
            }

#line 73 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\sip/QtQuick/qsgmaterial.sip"
        const char * const *names = sipCpp->attributeNames();
        
        SIP_SSIZE_T nr_names = 0;
        
        if (names)
            while (names[nr_names])
                ++nr_names;
            
        sipRes = PyList_New(nr_names);
            
        if (!sipRes)
            sipIsErr = 1;
        else
            for (SIP_SSIZE_T i = 0; i < nr_names; ++i)
            {
                const char *name = names[i];
                PyObject *el;
        
        #if PY_MAJOR_VERSION >= 3
                el = PyUnicode_DecodeASCII(name, strlen(name), 0);
        #else
                el = PyString_FromString(name);
        #endif
                
                if (!el)
                {
                    Py_DECREF(sipRes);
                    sipIsErr = 1;
                    break;
                }
        
                PyList_SET_ITEM(sipRes, i, el);
            }
#line 410 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\QtQuick/sipQtQuickQSGMaterialShader.cpp"

            if (sipIsErr)
                return 0;

            return sipRes;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QSGMaterialShader, sipName_attributeNames, doc_QSGMaterialShader_attributeNames);

    return NULL;
}
Пример #12
0
static PyObject *meth_QSignalMapper_setMapping(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        QObject* a0;
        int a1;
        QSignalMapper *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ8i", &sipSelf, sipType_QSignalMapper, &sipCpp, sipType_QObject, &a0, &a1))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->setMapping(a0,a1);
            Py_END_ALLOW_THREADS

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
        QObject* a0;
        const QString* a1;
        int a1State = 0;
        QSignalMapper *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ8J1", &sipSelf, sipType_QSignalMapper, &sipCpp, sipType_QObject, &a0, sipType_QString,&a1, &a1State))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->setMapping(a0,*a1);
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
        QObject* a0;
        QWidget* a1;
        QSignalMapper *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ8J8", &sipSelf, sipType_QSignalMapper, &sipCpp, sipType_QObject, &a0, sipType_QWidget, &a1))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->setMapping(a0,a1);
            Py_END_ALLOW_THREADS

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    {
        QObject* a0;
        QObject* a1;
        QSignalMapper *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ8J8", &sipSelf, sipType_QSignalMapper, &sipCpp, sipType_QObject, &a0, sipType_QObject, &a1))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->setMapping(a0,a1);
            Py_END_ALLOW_THREADS

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QSignalMapper, sipName_setMapping, doc_QSignalMapper_setMapping);

    return NULL;
}
Пример #13
0
static PyObject *slot_QPolygonF___getitem__(PyObject *sipSelf,PyObject *sipArg)
{
    QPolygonF *sipCpp = reinterpret_cast<QPolygonF *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QPolygonF));

    if (!sipCpp)
        return 0;

    PyObject *sipParseErr = NULL;

    {
        int a0;

        if (sipParseArgs(&sipParseErr, sipArg, "1i", &a0))
        {
            QPointF*sipRes = 0;
            int sipIsErr = 0;

#line 400 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\sip/QtGui/qpolygon.sip"
SIP_SSIZE_T idx = sipConvertFromSequenceIndex(a0, sipCpp->count());

if (idx < 0)
    sipIsErr = 1;
else
    sipRes = new QPointF(sipCpp->operator[]((int)idx));
#line 1231 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\QtGui/sipQtGuiQPolygonF.cpp"

            if (sipIsErr)
                return 0;

            return sipConvertFromType(sipRes,sipType_QPointF,NULL);
        }
    }

    {
        PyObject * a0;

        if (sipParseArgs(&sipParseErr, sipArg, "1T", &PySlice_Type, &a0))
        {
            QPolygonF*sipRes = 0;
            int sipIsErr = 0;

#line 491 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\sip/QtGui/qpolygon.sip"
SIP_SSIZE_T len, start, stop, step, slicelength, i;

len = sipCpp->count();

#if PY_VERSION_HEX >= 0x03020000
if (PySlice_GetIndicesEx(a0, len, &start, &stop, &step, &slicelength) < 0)
#else
if (PySlice_GetIndicesEx((PySliceObject *)a0, len, &start, &stop, &step, &slicelength) < 0)
#endif
    sipIsErr = 1;
else
{
    sipRes = new QPolygonF();

    for (i = 0; i < slicelength; ++i)
    {
        (*sipRes) += (*sipCpp)[start];
        start += step;
    }
}
#line 1269 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\QtGui/sipQtGuiQPolygonF.cpp"

            if (sipIsErr)
                return 0;

            return sipConvertFromType(sipRes,sipType_QPolygonF,NULL);
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QPolygonF, sipName___getitem__, NULL);

    return 0;
}
Пример #14
0
static int slot_QPolygonF___setitem__(PyObject *sipSelf,PyObject *sipArgs)
{
    QPolygonF *sipCpp = reinterpret_cast<QPolygonF *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QPolygonF));

    if (!sipCpp)
        return -1;

    PyObject *sipParseErr = NULL;

    {
        int a0;
        const QPointF* a1;
        int a1State = 0;

        if (sipParseArgs(&sipParseErr, sipArgs, "iJ1", &a0, sipType_QPointF, &a1, &a1State))
        {
            int sipIsErr = 0;

#line 412 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\sip/QtGui/qpolygon.sip"
int len;

len = sipCpp->count();

if ((a0 = (int)sipConvertFromSequenceIndex(a0, len)) < 0)
    sipIsErr = 1;
else
    (*sipCpp)[a0] = *a1;
#line 1140 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\QtGui/sipQtGuiQPolygonF.cpp"
            sipReleaseType(const_cast<QPointF *>(a1),sipType_QPointF,a1State);

            if (sipIsErr)
                return -1;

            return 0;
        }
    }

    {
        PyObject * a0;
        const QPolygonF* a1;

        if (sipParseArgs(&sipParseErr, sipArgs, "TJ9", &PySlice_Type, &a0, sipType_QPolygonF, &a1))
        {
            int sipIsErr = 0;

#line 424 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\sip/QtGui/qpolygon.sip"
SIP_SSIZE_T len, start, stop, step, slicelength, i;

len = sipCpp->count();

#if PY_VERSION_HEX >= 0x03020000
if (PySlice_GetIndicesEx(a0, len, &start, &stop, &step, &slicelength) < 0)
#else
if (PySlice_GetIndicesEx((PySliceObject *)a0, len, &start, &stop, &step, &slicelength) < 0)
#endif
    sipIsErr = 1;
else
{
    int vlen = a1->count();

    if (vlen != slicelength)
    {
        sipBadLengthForSlice(vlen, slicelength);
        sipIsErr = 1;
    }
    else
    {
        QVector<QPointF>::const_iterator it = a1->begin();

        for (i = 0; i < slicelength; ++i)
        {
            (*sipCpp)[start] = *it;
            start += step;
            ++it;
        }
    }
}
#line 1190 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\QtGui/sipQtGuiQPolygonF.cpp"

            if (sipIsErr)
                return -1;

            return 0;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QPolygonF, sipName___setitem__, NULL);

    return -1;
}
Пример #15
0
static int slot_QPolygonF___delitem__(PyObject *sipSelf,PyObject *sipArg)
{
    QPolygonF *sipCpp = reinterpret_cast<QPolygonF *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QPolygonF));

    if (!sipCpp)
        return -1;

    PyObject *sipParseErr = NULL;

    {
        int a0;

        if (sipParseArgs(&sipParseErr, sipArg, "1i", &a0))
        {
            int sipIsErr = 0;

#line 459 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\sip/QtGui/qpolygon.sip"
int len;

len = sipCpp->count();

if ((a0 = (int)sipConvertFromSequenceIndex(a0, len)) < 0)
    sipIsErr = 1;
else
    sipCpp->remove(a0);
#line 1063 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\QtGui/sipQtGuiQPolygonF.cpp"

            if (sipIsErr)
                return -1;

            return 0;
        }
    }

    {
        PyObject * a0;

        if (sipParseArgs(&sipParseErr, sipArg, "1T", &PySlice_Type, &a0))
        {
            int sipIsErr = 0;

#line 471 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\sip/QtGui/qpolygon.sip"
SIP_SSIZE_T len, start, stop, step, slicelength, i;

len = sipCpp->count();

#if PY_VERSION_HEX >= 0x03020000
if (PySlice_GetIndicesEx(a0, len, &start, &stop, &step, &slicelength) < 0)
#else
if (PySlice_GetIndicesEx((PySliceObject *)a0, len, &start, &stop, &step, &slicelength) < 0)
#endif
    sipIsErr = 1;
else
    for (i = 0; i < slicelength; ++i)
    {
        sipCpp->remove(start);
        start += step - 1;
    }
#line 1096 "C:\\Users\\marcus\\Downloads\\PyQt-gpl-5.4\\PyQt-gpl-5.4\\QtGui/sipQtGuiQPolygonF.cpp"

            if (sipIsErr)
                return -1;

            return 0;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QPolygonF, sipName___delitem__, NULL);

    return -1;
}