/*
 * Module code.
 *
 * Generated by SIP 4.18.1
 */

#include "sipAPIkutils.h"

#line 23 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/src/pykde4-4.14.3/sip/kutils/kidletime.sip"
#include <kidletime.h>
#line 12 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"

#line 729 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/src/pykde4-4.14.3/sip/kdecore/typedefs.sip"
#include <qhash.h>
#line 16 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 26 "/usr/share/python3-sip/PyQt4/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 19 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 368 "/usr/share/python3-sip/PyQt4/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 22 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 351 "/usr/share/python3-sip/PyQt4/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 25 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 29 "/usr/share/python3-sip/PyQt4/QtCore/qobject.sip"
#include <qobject.h>
#line 28 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 269 "/usr/share/python3-sip/PyQt4/QtCore/qvariant.sip"
#include <qvariant.h>
#line 31 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 28 "/usr/share/python3-sip/PyQt4/QtCore/qlist.sip"
#include <qlist.h>
#line 34 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 32 "/usr/share/python3-sip/PyQt4/QtCore/qbytearray.sip"
#include <qbytearray.h>
#line 37 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 30 "/usr/share/python3-sip/PyQt4/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 40 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 115 "/usr/share/python3-sip/PyQt4/QtCore/qlist.sip"
#include <qlist.h>
#line 43 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 26 "/usr/share/python3-sip/PyQt4/QtCore/qthread.sip"
#include <qthread.h>
#line 46 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 31 "/usr/share/python3-sip/PyQt4/QtCore/qstring.sip"
#include <qstring.h>
#line 49 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 30 "/usr/share/python3-sip/PyQt4/QtCore/qregexp.sip"
#include <qregexp.h>
#line 52 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 26 "/usr/share/python3-sip/PyQt4/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 55 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"


extern "C" {static PyObject *meth_KIdleTime_instance(PyObject *, PyObject *);}
static PyObject *meth_KIdleTime_instance(PyObject *, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        if (sipParseArgs(&sipParseErr, sipArgs, ""))
        {
            KIdleTime*sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = KIdleTime::instance();
            Py_END_ALLOW_THREADS

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

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

    return NULL;
}


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

    {
        const KIdleTime *sipCpp;

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

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->idleTime();
            Py_END_ALLOW_THREADS

            return SIPLong_FromLong(sipRes);
        }
    }

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

    return NULL;
}


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

    {
        const KIdleTime *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_KIdleTime, &sipCpp))
        {
            QHash<int,int>*sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new QHash<int,int>(sipCpp->idleTimeouts());
            Py_END_ALLOW_THREADS

            return sipConvertFromNewType(sipRes,sipType_QHash_1800_1800,NULL);
        }
    }

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

    return NULL;
}


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

    {
        KIdleTime *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_KIdleTime, &sipCpp))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->simulateUserActivity();
            Py_END_ALLOW_THREADS

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

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

    return NULL;
}


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

    {
        int a0;
        KIdleTime *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bi", &sipSelf, sipType_KIdleTime, &sipCpp, &a0))
        {
            int sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = sipCpp->addIdleTimeout(a0);
            Py_END_ALLOW_THREADS

            return SIPLong_FromLong(sipRes);
        }
    }

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

    return NULL;
}


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

    {
        int a0;
        KIdleTime *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bi", &sipSelf, sipType_KIdleTime, &sipCpp, &a0))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->removeIdleTimeout(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_KIdleTime, sipName_removeIdleTimeout, NULL);

    return NULL;
}


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

    {
        KIdleTime *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_KIdleTime, &sipCpp))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->removeAllIdleTimeouts();
            Py_END_ALLOW_THREADS

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

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

    return NULL;
}


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

    {
        KIdleTime *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_KIdleTime, &sipCpp))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->catchNextResumeEvent();
            Py_END_ALLOW_THREADS

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

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

    return NULL;
}


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

    {
        KIdleTime *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_KIdleTime, &sipCpp))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->stopCatchingResumeEvent();
            Py_END_ALLOW_THREADS

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

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

    return NULL;
}


/* Call the instance's destructor. */
extern "C" {static void release_KIdleTime(void *, int);}
static void release_KIdleTime(void *sipCppV,int)
{
    KIdleTime *sipCpp = reinterpret_cast<KIdleTime *>(sipCppV);

    Py_BEGIN_ALLOW_THREADS

    if (QThread::currentThread() == sipCpp->thread())
        delete sipCpp;
    else
        sipCpp->deleteLater();

    Py_END_ALLOW_THREADS
}


extern "C" {static void dealloc_KIdleTime(sipSimpleWrapper *);}
static void dealloc_KIdleTime(sipSimpleWrapper *sipSelf)
{
    if (sipIsPyOwned(sipSelf))
    {
        release_KIdleTime(sipGetAddress(sipSelf),0);
    }
}


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


static PyMethodDef methods_KIdleTime[] = {
    {SIP_MLNAME_CAST(sipName_addIdleTimeout), meth_KIdleTime_addIdleTimeout, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_catchNextResumeEvent), meth_KIdleTime_catchNextResumeEvent, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_idleTime), meth_KIdleTime_idleTime, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_idleTimeouts), meth_KIdleTime_idleTimeouts, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_instance), meth_KIdleTime_instance, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_removeAllIdleTimeouts), meth_KIdleTime_removeAllIdleTimeouts, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_removeIdleTimeout), meth_KIdleTime_removeIdleTimeout, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_simulateUserActivity), meth_KIdleTime_simulateUserActivity, METH_VARARGS, NULL},
    {SIP_MLNAME_CAST(sipName_stopCatchingResumeEvent), meth_KIdleTime_stopCatchingResumeEvent, METH_VARARGS, NULL}
};


/* Define this type's signals. */
static const pyqt4QtSignal signals_KIdleTime[] = {
    {"timeoutReached(int)", 0, 0, 0},
    {"timeoutReached(int,int)", 0, 0, 0},
    {"resumingFromIdle()", 0, 0, 0},
    {0, 0, 0, 0}
};


pyqt4ClassTypeDef sipTypeDef_kutils_KIdleTime = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_SCC|SIP_TYPE_CLASS,
        sipNameNr_KIdleTime,
        {0}
    },
    {
        sipNameNr_KIdleTime,
        {0, 0, 1},
        9, methods_KIdleTime,
        0, 0,
        0, 0,
        {0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    },
    0,
    -1,
    -1,
    supers_KIdleTime,
    0,
    0,
    0,
    0,
#if PY_MAJOR_VERSION >= 3
    0,
    0,
#else
    0,
    0,
    0,
    0,
#endif
    dealloc_KIdleTime,
    0,
    0,
    0,
    release_KIdleTime,
    0,
    0,
    0,
    0,
    0,
    0,
    0
},
    &KIdleTime::staticMetaObject,
    0,
    signals_KIdleTime,
};

#line 25 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/src/pykde4-4.14.3/sip/kutils/kemoticonstheme.sip"
#include <kemoticonstheme.h>
#line 404 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"

#line 31 "/usr/share/python3-sip/PyQt4/QtCore/qstring.sip"
#include <qstring.h>
#line 408 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
#line 25 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/src/pykde4-4.14.3/sip/kutils/kemoticonstheme.sip"
#include <kemoticonstheme.h>
#line 411 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"


/* Call the instance's destructor. */
extern "C" {static void release_KEmoticonsTheme_Token(void *, int);}
static void release_KEmoticonsTheme_Token(void *sipCppV,int)
{
    Py_BEGIN_ALLOW_THREADS

    delete reinterpret_cast<KEmoticonsTheme::Token *>(sipCppV);

    Py_END_ALLOW_THREADS
}


extern "C" {static void assign_KEmoticonsTheme_Token(void *, SIP_SSIZE_T, const void *);}
static void assign_KEmoticonsTheme_Token(void *sipDst, SIP_SSIZE_T sipDstIdx, const void *sipSrc)
{
    reinterpret_cast<KEmoticonsTheme::Token *>(sipDst)[sipDstIdx] = *reinterpret_cast<const KEmoticonsTheme::Token *>(sipSrc);
}


extern "C" {static void *array_KEmoticonsTheme_Token(SIP_SSIZE_T);}
static void *array_KEmoticonsTheme_Token(SIP_SSIZE_T sipNrElem)
{
    return new KEmoticonsTheme::Token[sipNrElem];
}


extern "C" {static void *copy_KEmoticonsTheme_Token(const void *, SIP_SSIZE_T);}
static void *copy_KEmoticonsTheme_Token(const void *sipSrc, SIP_SSIZE_T sipSrcIdx)
{
    return new KEmoticonsTheme::Token(reinterpret_cast<const KEmoticonsTheme::Token *>(sipSrc)[sipSrcIdx]);
}


extern "C" {static void dealloc_KEmoticonsTheme_Token(sipSimpleWrapper *);}
static void dealloc_KEmoticonsTheme_Token(sipSimpleWrapper *sipSelf)
{
    if (sipIsPyOwned(sipSelf))
    {
        release_KEmoticonsTheme_Token(sipGetAddress(sipSelf),0);
    }
}


extern "C" {static void *init_type_KEmoticonsTheme_Token(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_type_KEmoticonsTheme_Token(sipSimpleWrapper *, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **, PyObject **sipParseErr)
{
    KEmoticonsTheme::Token *sipCpp = 0;

    {
        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, ""))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new KEmoticonsTheme::Token();
            Py_END_ALLOW_THREADS

            return sipCpp;
        }
    }

    {
        KEmoticonsTheme::TokenType a0;
        const QString* a1;
        int a1State = 0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, "EJ1", sipType_KEmoticonsTheme_TokenType, &a0, sipType_QString,&a1, &a1State))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new KEmoticonsTheme::Token(a0,*a1);
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);

            return sipCpp;
        }
    }

    {
        KEmoticonsTheme::TokenType a0;
        const QString* a1;
        int a1State = 0;
        const QString* a2;
        int a2State = 0;
        const QString* a3;
        int a3State = 0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, "EJ1J1J1", sipType_KEmoticonsTheme_TokenType, &a0, sipType_QString,&a1, &a1State, sipType_QString,&a2, &a2State, sipType_QString,&a3, &a3State))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new KEmoticonsTheme::Token(a0,*a1,*a2,*a3);
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast<QString *>(a1),sipType_QString,a1State);
            sipReleaseType(const_cast<QString *>(a2),sipType_QString,a2State);
            sipReleaseType(const_cast<QString *>(a3),sipType_QString,a3State);

            return sipCpp;
        }
    }

    {
        const KEmoticonsTheme::Token* a0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, "J9", sipType_KEmoticonsTheme_Token, &a0))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new KEmoticonsTheme::Token(*a0);
            Py_END_ALLOW_THREADS

            return sipCpp;
        }
    }

    return NULL;
}


extern "C" {static PyObject *varget_KEmoticonsTheme_Token_picHTMLCode(void *, PyObject *, PyObject *);}
static PyObject *varget_KEmoticonsTheme_Token_picHTMLCode(void *sipSelf, PyObject *sipPySelf, PyObject *)
{
    PyObject *sipPy;
    QString*sipVal;
    KEmoticonsTheme::Token *sipCpp = reinterpret_cast<KEmoticonsTheme::Token *>(sipSelf);

    sipPy = sipGetReference(sipPySelf, -1);
    if (sipPy)
        return sipPy;

    sipVal = &sipCpp->picHTMLCode;

    sipPy = sipConvertFromType(sipVal, sipType_QString, NULL);
    sipKeepReference(sipPySelf, -1, sipPy);

    return sipPy;
}


extern "C" {static int varset_KEmoticonsTheme_Token_picHTMLCode(void *, PyObject *, PyObject *);}
static int varset_KEmoticonsTheme_Token_picHTMLCode(void *sipSelf, PyObject *sipPy, PyObject *)
{
    QString*sipVal;
    KEmoticonsTheme::Token *sipCpp = reinterpret_cast<KEmoticonsTheme::Token *>(sipSelf);

    int sipValState;
    int sipIsErr = 0;

    sipVal = reinterpret_cast<QString *>(sipForceConvertToType(sipPy,sipType_QString,NULL,SIP_NOT_NONE,&sipValState,&sipIsErr));

    if (sipIsErr)
        return -1;

    sipCpp->picHTMLCode = *sipVal;

    sipReleaseType(sipVal, sipType_QString, sipValState);

    return 0;
}


extern "C" {static PyObject *varget_KEmoticonsTheme_Token_picPath(void *, PyObject *, PyObject *);}
static PyObject *varget_KEmoticonsTheme_Token_picPath(void *sipSelf, PyObject *sipPySelf, PyObject *)
{
    PyObject *sipPy;
    QString*sipVal;
    KEmoticonsTheme::Token *sipCpp = reinterpret_cast<KEmoticonsTheme::Token *>(sipSelf);

    sipPy = sipGetReference(sipPySelf, -2);
    if (sipPy)
        return sipPy;

    sipVal = &sipCpp->picPath;

    sipPy = sipConvertFromType(sipVal, sipType_QString, NULL);
    sipKeepReference(sipPySelf, -2, sipPy);

    return sipPy;
}


extern "C" {static int varset_KEmoticonsTheme_Token_picPath(void *, PyObject *, PyObject *);}
static int varset_KEmoticonsTheme_Token_picPath(void *sipSelf, PyObject *sipPy, PyObject *)
{
    QString*sipVal;
    KEmoticonsTheme::Token *sipCpp = reinterpret_cast<KEmoticonsTheme::Token *>(sipSelf);

    int sipValState;
    int sipIsErr = 0;

    sipVal = reinterpret_cast<QString *>(sipForceConvertToType(sipPy,sipType_QString,NULL,SIP_NOT_NONE,&sipValState,&sipIsErr));

    if (sipIsErr)
        return -1;

    sipCpp->picPath = *sipVal;

    sipReleaseType(sipVal, sipType_QString, sipValState);

    return 0;
}


extern "C" {static PyObject *varget_KEmoticonsTheme_Token_text(void *, PyObject *, PyObject *);}
static PyObject *varget_KEmoticonsTheme_Token_text(void *sipSelf, PyObject *sipPySelf, PyObject *)
{
    PyObject *sipPy;
    QString*sipVal;
    KEmoticonsTheme::Token *sipCpp = reinterpret_cast<KEmoticonsTheme::Token *>(sipSelf);

    sipPy = sipGetReference(sipPySelf, -3);
    if (sipPy)
        return sipPy;

    sipVal = &sipCpp->text;

    sipPy = sipConvertFromType(sipVal, sipType_QString, NULL);
    sipKeepReference(sipPySelf, -3, sipPy);

    return sipPy;
}


extern "C" {static int varset_KEmoticonsTheme_Token_text(void *, PyObject *, PyObject *);}
static int varset_KEmoticonsTheme_Token_text(void *sipSelf, PyObject *sipPy, PyObject *)
{
    QString*sipVal;
    KEmoticonsTheme::Token *sipCpp = reinterpret_cast<KEmoticonsTheme::Token *>(sipSelf);

    int sipValState;
    int sipIsErr = 0;

    sipVal = reinterpret_cast<QString *>(sipForceConvertToType(sipPy,sipType_QString,NULL,SIP_NOT_NONE,&sipValState,&sipIsErr));

    if (sipIsErr)
        return -1;

    sipCpp->text = *sipVal;

    sipReleaseType(sipVal, sipType_QString, sipValState);

    return 0;
}


extern "C" {static PyObject *varget_KEmoticonsTheme_Token_type(void *, PyObject *, PyObject *);}
static PyObject *varget_KEmoticonsTheme_Token_type(void *sipSelf, PyObject *, PyObject *)
{
    KEmoticonsTheme::TokenType sipVal;
    KEmoticonsTheme::Token *sipCpp = reinterpret_cast<KEmoticonsTheme::Token *>(sipSelf);

    sipVal = sipCpp->type;

    return sipConvertFromEnum(sipVal, sipType_KEmoticonsTheme_TokenType);
}


extern "C" {static int varset_KEmoticonsTheme_Token_type(void *, PyObject *, PyObject *);}
static int varset_KEmoticonsTheme_Token_type(void *sipSelf, PyObject *sipPy, PyObject *)
{
    KEmoticonsTheme::TokenType sipVal;
    KEmoticonsTheme::Token *sipCpp = reinterpret_cast<KEmoticonsTheme::Token *>(sipSelf);

    sipVal = (KEmoticonsTheme::TokenType)SIPLong_AsLong(sipPy);

    if (PyErr_Occurred() != NULL)
        return -1;

    sipCpp->type = sipVal;

    return 0;
}

sipVariableDef variables_KEmoticonsTheme_Token[] = {
    {InstanceVariable, sipName_picHTMLCode, (PyMethodDef *)varget_KEmoticonsTheme_Token_picHTMLCode, (PyMethodDef *)varset_KEmoticonsTheme_Token_picHTMLCode, NULL, NULL},
    {InstanceVariable, sipName_picPath, (PyMethodDef *)varget_KEmoticonsTheme_Token_picPath, (PyMethodDef *)varset_KEmoticonsTheme_Token_picPath, NULL, NULL},
    {InstanceVariable, sipName_text, (PyMethodDef *)varget_KEmoticonsTheme_Token_text, (PyMethodDef *)varset_KEmoticonsTheme_Token_text, NULL, NULL},
    {InstanceVariable, sipName_type, (PyMethodDef *)varget_KEmoticonsTheme_Token_type, (PyMethodDef *)varset_KEmoticonsTheme_Token_type, NULL, NULL},
};


pyqt4ClassTypeDef sipTypeDef_kutils_KEmoticonsTheme_Token = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_CLASS,
        sipNameNr_KEmoticonsTheme__Token,
        {0}
    },
    {
        sipNameNr_Token,
        {9, 255, 0},
        0, 0,
        0, 0,
        4, variables_KEmoticonsTheme_Token,
        {0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    },
    0,
    sipNameNr_PyQt4_QtCore_pyqtWrapperType,
    -1,
    0,
    0,
    init_type_KEmoticonsTheme_Token,
    0,
    0,
#if PY_MAJOR_VERSION >= 3
    0,
    0,
#else
    0,
    0,
    0,
    0,
#endif
    dealloc_KEmoticonsTheme_Token,
    assign_KEmoticonsTheme_Token,
    array_KEmoticonsTheme_Token,
    copy_KEmoticonsTheme_Token,
    release_KEmoticonsTheme_Token,
    0,
    0,
    0,
    0,
    0,
    0,
    0
},
    0,
    0,
    0
};

#line 25 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/src/pykde4-4.14.3/sip/kutils/kemoticonstheme.sip"
#include <kemoticonstheme.h>
#line 745 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"

#line 25 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/src/pykde4-4.14.3/sip/kutils/kemoticonstheme.sip"
#include <kemoticonstheme.h>
#line 749 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"


extern "C" {static int slot_KEmoticonsTheme_ParseMode___bool__(PyObject *);}
static int slot_KEmoticonsTheme_ParseMode___bool__(PyObject *sipSelf)
{
    KEmoticonsTheme::ParseMode *sipCpp = reinterpret_cast<KEmoticonsTheme::ParseMode *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_KEmoticonsTheme_ParseMode));

    if (!sipCpp)
        return -1;


    {
        {
            int sipRes = 0;

#line 389 "/usr/share/python3-sip/PyQt4/QtCore/qglobal.sip"
#if QT_VERSION >= 0x050000
        sipRes = (sipCpp->operator KEmoticonsTheme::ParseMode::Int() != 0);
#else
        sipRes = (sipCpp->operator int() != 0);
#endif
#line 771 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"

            return sipRes;
        }
    }

    return 0;
}


extern "C" {static PyObject *slot_KEmoticonsTheme_ParseMode___ne__(PyObject *,PyObject *);}
static PyObject *slot_KEmoticonsTheme_ParseMode___ne__(PyObject *sipSelf,PyObject *sipArg)
{
    KEmoticonsTheme::ParseMode *sipCpp = reinterpret_cast<KEmoticonsTheme::ParseMode *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_KEmoticonsTheme_ParseMode));

    if (!sipCpp)
        return 0;

    PyObject *sipParseErr = NULL;

    {
        const KEmoticonsTheme::ParseMode* a0;
        int a0State = 0;

        if (sipParseArgs(&sipParseErr, sipArg, "1J1", sipType_KEmoticonsTheme_ParseMode, &a0, &a0State))
        {
            bool sipRes = 0;

#line 380 "/usr/share/python3-sip/PyQt4/QtCore/qglobal.sip"
#if QT_VERSION >= 0x050000
        sipRes = (sipCpp->operator KEmoticonsTheme::ParseMode::Int() != a0->operator KEmoticonsTheme::ParseMode::Int());
#else
        sipRes = (sipCpp->operator int() != a0->operator int());
#endif
#line 805 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
            sipReleaseType(const_cast<KEmoticonsTheme::ParseMode *>(a0),sipType_KEmoticonsTheme_ParseMode,a0State);

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return NULL;

    return sipPySlotExtend(&sipModuleAPI_kutils,ne_slot,sipType_KEmoticonsTheme_ParseMode,sipSelf,sipArg);
}


extern "C" {static PyObject *slot_KEmoticonsTheme_ParseMode___eq__(PyObject *,PyObject *);}
static PyObject *slot_KEmoticonsTheme_ParseMode___eq__(PyObject *sipSelf,PyObject *sipArg)
{
    KEmoticonsTheme::ParseMode *sipCpp = reinterpret_cast<KEmoticonsTheme::ParseMode *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_KEmoticonsTheme_ParseMode));

    if (!sipCpp)
        return 0;

    PyObject *sipParseErr = NULL;

    {
        const KEmoticonsTheme::ParseMode* a0;
        int a0State = 0;

        if (sipParseArgs(&sipParseErr, sipArg, "1J1", sipType_KEmoticonsTheme_ParseMode, &a0, &a0State))
        {
            bool sipRes = 0;

#line 371 "/usr/share/python3-sip/PyQt4/QtCore/qglobal.sip"
#if QT_VERSION >= 0x050000
        sipRes = (sipCpp->operator KEmoticonsTheme::ParseMode::Int() == a0->operator KEmoticonsTheme::ParseMode::Int());
#else
        sipRes = (sipCpp->operator int() == a0->operator int());
#endif
#line 845 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
            sipReleaseType(const_cast<KEmoticonsTheme::ParseMode *>(a0),sipType_KEmoticonsTheme_ParseMode,a0State);

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return NULL;

    return sipPySlotExtend(&sipModuleAPI_kutils,eq_slot,sipType_KEmoticonsTheme_ParseMode,sipSelf,sipArg);
}


extern "C" {static PyObject *slot_KEmoticonsTheme_ParseMode___invert__(PyObject *);}
static PyObject *slot_KEmoticonsTheme_ParseMode___invert__(PyObject *sipSelf)
{
    KEmoticonsTheme::ParseMode *sipCpp = reinterpret_cast<KEmoticonsTheme::ParseMode *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_KEmoticonsTheme_ParseMode));

    if (!sipCpp)
        return 0;


    {
        {
            KEmoticonsTheme::ParseMode*sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new KEmoticonsTheme::ParseMode(~(*sipCpp));
            Py_END_ALLOW_THREADS

            return sipConvertFromNewType(sipRes,sipType_KEmoticonsTheme_ParseMode,NULL);
        }
    }

    return 0;
}


extern "C" {static PyObject *slot_KEmoticonsTheme_ParseMode___and__(PyObject *,PyObject *);}
static PyObject *slot_KEmoticonsTheme_ParseMode___and__(PyObject *sipArg0,PyObject *sipArg1)
{
    PyObject *sipParseErr = NULL;

    {
        KEmoticonsTheme::ParseMode* a0;
        int a0State = 0;
        int a1;

        if (sipParsePair(&sipParseErr, sipArg0, sipArg1, "J1i", sipType_KEmoticonsTheme_ParseMode, &a0, &a0State, &a1))
        {
            KEmoticonsTheme::ParseMode*sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new KEmoticonsTheme::ParseMode((*a0 & a1));
            Py_END_ALLOW_THREADS
            sipReleaseType(a0,sipType_KEmoticonsTheme_ParseMode,a0State);

            return sipConvertFromNewType(sipRes,sipType_KEmoticonsTheme_ParseMode,NULL);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return NULL;

    return sipPySlotExtend(&sipModuleAPI_kutils,and_slot,NULL,sipArg0,sipArg1);
}


extern "C" {static PyObject *slot_KEmoticonsTheme_ParseMode___xor__(PyObject *,PyObject *);}
static PyObject *slot_KEmoticonsTheme_ParseMode___xor__(PyObject *sipArg0,PyObject *sipArg1)
{
    PyObject *sipParseErr = NULL;

    {
        KEmoticonsTheme::ParseMode* a0;
        int a0State = 0;
        KEmoticonsTheme::ParseMode* a1;
        int a1State = 0;

        if (sipParsePair(&sipParseErr, sipArg0, sipArg1, "J1J1", sipType_KEmoticonsTheme_ParseMode, &a0, &a0State, sipType_KEmoticonsTheme_ParseMode, &a1, &a1State))
        {
            KEmoticonsTheme::ParseMode*sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new KEmoticonsTheme::ParseMode((*a0 ^ *a1));
            Py_END_ALLOW_THREADS
            sipReleaseType(a0,sipType_KEmoticonsTheme_ParseMode,a0State);
            sipReleaseType(a1,sipType_KEmoticonsTheme_ParseMode,a1State);

            return sipConvertFromNewType(sipRes,sipType_KEmoticonsTheme_ParseMode,NULL);
        }
    }

    {
        KEmoticonsTheme::ParseMode* a0;
        int a0State = 0;
        int a1;

        if (sipParsePair(&sipParseErr, sipArg0, sipArg1, "J1i", sipType_KEmoticonsTheme_ParseMode, &a0, &a0State, &a1))
        {
            KEmoticonsTheme::ParseMode*sipRes = 0;

#line 365 "/usr/share/python3-sip/PyQt4/QtCore/qglobal.sip"
        sipRes = new KEmoticonsTheme::ParseMode(*a0 ^ a1);
#line 954 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
            sipReleaseType(a0,sipType_KEmoticonsTheme_ParseMode,a0State);

            return sipConvertFromNewType(sipRes,sipType_KEmoticonsTheme_ParseMode,NULL);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return NULL;

    return sipPySlotExtend(&sipModuleAPI_kutils,xor_slot,NULL,sipArg0,sipArg1);
}


extern "C" {static PyObject *slot_KEmoticonsTheme_ParseMode___or__(PyObject *,PyObject *);}
static PyObject *slot_KEmoticonsTheme_ParseMode___or__(PyObject *sipArg0,PyObject *sipArg1)
{
    PyObject *sipParseErr = NULL;

    {
        KEmoticonsTheme::ParseMode* a0;
        int a0State = 0;
        KEmoticonsTheme::ParseMode* a1;
        int a1State = 0;

        if (sipParsePair(&sipParseErr, sipArg0, sipArg1, "J1J1", sipType_KEmoticonsTheme_ParseMode, &a0, &a0State, sipType_KEmoticonsTheme_ParseMode, &a1, &a1State))
        {
            KEmoticonsTheme::ParseMode*sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = new KEmoticonsTheme::ParseMode((*a0 | *a1));
            Py_END_ALLOW_THREADS
            sipReleaseType(a0,sipType_KEmoticonsTheme_ParseMode,a0State);
            sipReleaseType(a1,sipType_KEmoticonsTheme_ParseMode,a1State);

            return sipConvertFromNewType(sipRes,sipType_KEmoticonsTheme_ParseMode,NULL);
        }
    }

    {
        KEmoticonsTheme::ParseMode* a0;
        int a0State = 0;
        int a1;

        if (sipParsePair(&sipParseErr, sipArg0, sipArg1, "J1i", sipType_KEmoticonsTheme_ParseMode, &a0, &a0State, &a1))
        {
            KEmoticonsTheme::ParseMode*sipRes = 0;

#line 360 "/usr/share/python3-sip/PyQt4/QtCore/qglobal.sip"
        sipRes = new KEmoticonsTheme::ParseMode(*a0 | a1);
#line 1006 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
            sipReleaseType(a0,sipType_KEmoticonsTheme_ParseMode,a0State);

            return sipConvertFromNewType(sipRes,sipType_KEmoticonsTheme_ParseMode,NULL);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return NULL;

    return sipPySlotExtend(&sipModuleAPI_kutils,or_slot,NULL,sipArg0,sipArg1);
}


extern "C" {static PyObject *slot_KEmoticonsTheme_ParseMode___int__(PyObject *);}
static PyObject *slot_KEmoticonsTheme_ParseMode___int__(PyObject *sipSelf)
{
    KEmoticonsTheme::ParseMode *sipCpp = reinterpret_cast<KEmoticonsTheme::ParseMode *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_KEmoticonsTheme_ParseMode));

    if (!sipCpp)
        return 0;


    {
        {
            int sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = *sipCpp;
            Py_END_ALLOW_THREADS

            return SIPLong_FromLong(sipRes);
        }
    }

    return 0;
}


extern "C" {static PyObject *slot_KEmoticonsTheme_ParseMode___ixor__(PyObject *,PyObject *);}
static PyObject *slot_KEmoticonsTheme_ParseMode___ixor__(PyObject *sipSelf,PyObject *sipArg)
{
    if (!PyObject_TypeCheck(sipSelf, sipTypeAsPyTypeObject(sipType_KEmoticonsTheme_ParseMode)))
    {
        Py_INCREF(Py_NotImplemented);
        return Py_NotImplemented;
    }

    KEmoticonsTheme::ParseMode *sipCpp = reinterpret_cast<KEmoticonsTheme::ParseMode *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_KEmoticonsTheme_ParseMode));

    if (!sipCpp)
        return 0;

    PyObject *sipParseErr = NULL;

    {
        KEmoticonsTheme::ParseMode* a0;
        int a0State = 0;

        if (sipParseArgs(&sipParseErr, sipArg, "1J1", sipType_KEmoticonsTheme_ParseMode, &a0, &a0State))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->KEmoticonsTheme::ParseMode::operator^=(*a0);
            Py_END_ALLOW_THREADS
            sipReleaseType(a0,sipType_KEmoticonsTheme_ParseMode,a0State);

            Py_INCREF(sipSelf);
            return sipSelf;
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return NULL;

    PyErr_Clear();

    Py_INCREF(Py_NotImplemented);
    return Py_NotImplemented;
}


extern "C" {static PyObject *slot_KEmoticonsTheme_ParseMode___ior__(PyObject *,PyObject *);}
static PyObject *slot_KEmoticonsTheme_ParseMode___ior__(PyObject *sipSelf,PyObject *sipArg)
{
    if (!PyObject_TypeCheck(sipSelf, sipTypeAsPyTypeObject(sipType_KEmoticonsTheme_ParseMode)))
    {
        Py_INCREF(Py_NotImplemented);
        return Py_NotImplemented;
    }

    KEmoticonsTheme::ParseMode *sipCpp = reinterpret_cast<KEmoticonsTheme::ParseMode *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_KEmoticonsTheme_ParseMode));

    if (!sipCpp)
        return 0;

    PyObject *sipParseErr = NULL;

    {
        KEmoticonsTheme::ParseMode* a0;
        int a0State = 0;

        if (sipParseArgs(&sipParseErr, sipArg, "1J1", sipType_KEmoticonsTheme_ParseMode, &a0, &a0State))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->KEmoticonsTheme::ParseMode::operator|=(*a0);
            Py_END_ALLOW_THREADS
            sipReleaseType(a0,sipType_KEmoticonsTheme_ParseMode,a0State);

            Py_INCREF(sipSelf);
            return sipSelf;
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return NULL;

    PyErr_Clear();

    Py_INCREF(Py_NotImplemented);
    return Py_NotImplemented;
}


extern "C" {static PyObject *slot_KEmoticonsTheme_ParseMode___iand__(PyObject *,PyObject *);}
static PyObject *slot_KEmoticonsTheme_ParseMode___iand__(PyObject *sipSelf,PyObject *sipArg)
{
    if (!PyObject_TypeCheck(sipSelf, sipTypeAsPyTypeObject(sipType_KEmoticonsTheme_ParseMode)))
    {
        Py_INCREF(Py_NotImplemented);
        return Py_NotImplemented;
    }

    KEmoticonsTheme::ParseMode *sipCpp = reinterpret_cast<KEmoticonsTheme::ParseMode *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_KEmoticonsTheme_ParseMode));

    if (!sipCpp)
        return 0;

    PyObject *sipParseErr = NULL;

    {
        int a0;

        if (sipParseArgs(&sipParseErr, sipArg, "1i", &a0))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp->KEmoticonsTheme::ParseMode::operator&=(a0);
            Py_END_ALLOW_THREADS

            Py_INCREF(sipSelf);
            return sipSelf;
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return NULL;

    PyErr_Clear();

    Py_INCREF(Py_NotImplemented);
    return Py_NotImplemented;
}


/* Call the instance's destructor. */
extern "C" {static void release_KEmoticonsTheme_ParseMode(void *, int);}
static void release_KEmoticonsTheme_ParseMode(void *sipCppV,int)
{
    Py_BEGIN_ALLOW_THREADS

    delete reinterpret_cast<KEmoticonsTheme::ParseMode *>(sipCppV);

    Py_END_ALLOW_THREADS
}


extern "C" {static void assign_KEmoticonsTheme_ParseMode(void *, SIP_SSIZE_T, const void *);}
static void assign_KEmoticonsTheme_ParseMode(void *sipDst, SIP_SSIZE_T sipDstIdx, const void *sipSrc)
{
    reinterpret_cast<KEmoticonsTheme::ParseMode *>(sipDst)[sipDstIdx] = *reinterpret_cast<const KEmoticonsTheme::ParseMode *>(sipSrc);
}


extern "C" {static void *array_KEmoticonsTheme_ParseMode(SIP_SSIZE_T);}
static void *array_KEmoticonsTheme_ParseMode(SIP_SSIZE_T sipNrElem)
{
    return new KEmoticonsTheme::ParseMode[sipNrElem];
}


extern "C" {static void *copy_KEmoticonsTheme_ParseMode(const void *, SIP_SSIZE_T);}
static void *copy_KEmoticonsTheme_ParseMode(const void *sipSrc, SIP_SSIZE_T sipSrcIdx)
{
    return new KEmoticonsTheme::ParseMode(reinterpret_cast<const KEmoticonsTheme::ParseMode *>(sipSrc)[sipSrcIdx]);
}


extern "C" {static void dealloc_KEmoticonsTheme_ParseMode(sipSimpleWrapper *);}
static void dealloc_KEmoticonsTheme_ParseMode(sipSimpleWrapper *sipSelf)
{
    if (sipIsPyOwned(sipSelf))
    {
        release_KEmoticonsTheme_ParseMode(sipGetAddress(sipSelf),0);
    }
}


extern "C" {static void *init_type_KEmoticonsTheme_ParseMode(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_type_KEmoticonsTheme_ParseMode(sipSimpleWrapper *, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **, PyObject **sipParseErr)
{
    KEmoticonsTheme::ParseMode *sipCpp = 0;

    {
        const KEmoticonsTheme::ParseMode* a0;
        int a0State = 0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, "J1", sipType_KEmoticonsTheme_ParseMode, &a0, &a0State))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new KEmoticonsTheme::ParseMode(*a0);
            Py_END_ALLOW_THREADS
            sipReleaseType(const_cast<KEmoticonsTheme::ParseMode *>(a0),sipType_KEmoticonsTheme_ParseMode,a0State);

            return sipCpp;
        }
    }

    {
        int a0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, "i", &a0))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new KEmoticonsTheme::ParseMode(a0);
            Py_END_ALLOW_THREADS

            return sipCpp;
        }
    }

    {
        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, ""))
        {
            Py_BEGIN_ALLOW_THREADS
            sipCpp = new KEmoticonsTheme::ParseMode();
            Py_END_ALLOW_THREADS

            return sipCpp;
        }
    }

    return NULL;
}


extern "C" {static int convertTo_KEmoticonsTheme_ParseMode(PyObject *, void **, int *, PyObject *);}
static int convertTo_KEmoticonsTheme_ParseMode(PyObject *sipPy,void **sipCppPtrV,int *sipIsErr,PyObject *sipTransferObj)
{
    KEmoticonsTheme::ParseMode **sipCppPtr = reinterpret_cast<KEmoticonsTheme::ParseMode **>(sipCppPtrV);

#line 398 "/usr/share/python3-sip/PyQt4/QtCore/qglobal.sip"
// Allow an instance of the base enum whenever a KEmoticonsTheme::ParseMode is expected.

if (sipIsErr == NULL)
    return (PyObject_TypeCheck(sipPy, sipTypeAsPyTypeObject(sipType_KEmoticonsTheme_ParseModeEnum)) ||
            sipCanConvertToType(sipPy, sipType_KEmoticonsTheme_ParseMode, SIP_NO_CONVERTORS));

if (PyObject_TypeCheck(sipPy, sipTypeAsPyTypeObject(sipType_KEmoticonsTheme_ParseModeEnum)))
{
    *sipCppPtr = new KEmoticonsTheme::ParseMode(int(SIPLong_AsLong(sipPy)));

    return sipGetState(sipTransferObj);
}

*sipCppPtr = reinterpret_cast<KEmoticonsTheme::ParseMode *>(sipConvertToType(sipPy, sipType_KEmoticonsTheme_ParseMode, sipTransferObj, SIP_NO_CONVERTORS, 0, sipIsErr));

return 0;
#line 1290 "/usr/src/ports/python3-pykde4/python3-pykde4-4.14.3-3.i686/build/sip/kutils/sipkutilspart2.cpp"
}


/* Define this type's Python slots. */
static sipPySlotDef slots_KEmoticonsTheme_ParseMode[] = {
    {(void *)slot_KEmoticonsTheme_ParseMode___bool__, bool_slot},
    {(void *)slot_KEmoticonsTheme_ParseMode___ne__, ne_slot},
    {(void *)slot_KEmoticonsTheme_ParseMode___eq__, eq_slot},
    {(void *)slot_KEmoticonsTheme_ParseMode___invert__, invert_slot},
    {(void *)slot_KEmoticonsTheme_ParseMode___and__, and_slot},
    {(void *)slot_KEmoticonsTheme_ParseMode___xor__, xor_slot},
    {(void *)slot_KEmoticonsTheme_ParseMode___or__, or_slot},
    {(void *)slot_KEmoticonsTheme_ParseMode___int__, int_slot},
    {(void *)slot_KEmoticonsTheme_ParseMode___ixor__, ixor_slot},
    {(void *)slot_KEmoticonsTheme_ParseMode___ior__, ior_slot},
    {(void *)slot_KEmoticonsTheme_ParseMode___iand__, iand_slot},
    {0, (sipPySlotType)0}
};


pyqt4ClassTypeDef sipTypeDef_kutils_KEmoticonsTheme_ParseMode = {
{
    {
        -1,
        0,
        0,
        SIP_TYPE_CLASS,
        sipNameNr_KEmoticonsTheme__ParseMode,
        {0}
    },
    {
        sipNameNr_ParseMode,
        {9, 255, 0},
        0, 0,
        0, 0,
        0, 0,
        {0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
    },
    0,
    sipNameNr_PyQt4_QtCore_pyqtWrapperType,
    -1,
    0,
    slots_KEmoticonsTheme_ParseMode,
    init_type_KEmoticonsTheme_ParseMode,
    0,
    0,
#if PY_MAJOR_VERSION >= 3
    0,
    0,
#else
    0,
    0,
    0,
    0,
#endif
    dealloc_KEmoticonsTheme_ParseMode,
    assign_KEmoticonsTheme_ParseMode,
    array_KEmoticonsTheme_ParseMode,
    copy_KEmoticonsTheme_ParseMode,
    release_KEmoticonsTheme_ParseMode,
    0,
    convertTo_KEmoticonsTheme_ParseMode,
    0,
    0,
    0,
    0,
    0
},
    0,
    1,
    0
};
