From 709c4d66e0b107ca606941b988bad717c0b45d9b Mon Sep 17 00:00:00 2001 From: Denys Dmytriyenko Date: Tue, 17 Mar 2009 14:32:59 -0400 Subject: rename packages/ to recipes/ per earlier agreement See links below for more details: http://thread.gmane.org/gmane.comp.handhelds.openembedded/21326 http://thread.gmane.org/gmane.comp.handhelds.openembedded/21816 Signed-off-by: Denys Dmytriyenko Acked-by: Mike Westerhof Acked-by: Philip Balister Acked-by: Khem Raj Acked-by: Marcin Juszkiewicz Acked-by: Koen Kooi Acked-by: Frans Meulenbroeks --- .../python/python-pyqt/04_qreal_api_fixes.dpatch | 259 +++++++++++++++++++++ 1 file changed, 259 insertions(+) create mode 100644 recipes/python/python-pyqt/04_qreal_api_fixes.dpatch (limited to 'recipes/python/python-pyqt/04_qreal_api_fixes.dpatch') diff --git a/recipes/python/python-pyqt/04_qreal_api_fixes.dpatch b/recipes/python/python-pyqt/04_qreal_api_fixes.dpatch new file mode 100644 index 0000000000..abd9e3f4cd --- /dev/null +++ b/recipes/python/python-pyqt/04_qreal_api_fixes.dpatch @@ -0,0 +1,259 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 04_qreal_api_fixes.dpatch by Torsten Marek +## +## DP: Exchanges double by qreal in some wrapped methods. + +@DPATCH@ +diff -urNad python-qt4-4.3~/sip/QtCore/qlist.sip python-qt4-4.3/sip/QtCore/qlist.sip +--- python-qt4-4.3~/sip/QtCore/qlist.sip 2007-09-02 00:35:50.000000000 +0200 ++++ python-qt4-4.3/sip/QtCore/qlist.sip 2007-09-02 00:35:53.000000000 +0200 +@@ -322,8 +322,8 @@ + %End + }; + %If (Qt_4_3_0 -) +-// QList > is implemented as a Python list of 2-element tuples. +-%MappedType QList > ++// QList > is implemented as a Python list of 2-element tuples. ++%MappedType QList > + { + %TypeHeaderCode + #include +@@ -340,7 +340,7 @@ + // Set the list elements. + for (int i = 0; i < sipCpp->size(); ++i) + { +- const QPair &p = sipCpp->at(i); ++ const QPair &p = sipCpp->at(i); + PyObject *pobj; + + if ((pobj = Py_BuildValue((char *)"dd", p.first, p.second)) == NULL) +@@ -370,16 +370,16 @@ + return 1; + } + +- QList > *ql = new QList >; ++ QList > *ql = new QList >; + + for (int i = 0; i < PyList_GET_SIZE(sipPy); ++i) + { + PyObject *tup = PyList_GET_ITEM(sipPy, i); + +- double first = PyFloat_AsDouble(PyTuple_GET_ITEM(tup, 0)); +- double second = PyFloat_AsDouble(PyTuple_GET_ITEM(tup, 1)); ++ float first = PyFloat_AsDouble(PyTuple_GET_ITEM(tup, 0)); ++ float second = PyFloat_AsDouble(PyTuple_GET_ITEM(tup, 1)); + +- ql->append(QPair(first, second)); ++ ql->append(QPair(first, second)); + } + + *sipCppPtr = ql; +@@ -389,9 +389,9 @@ + }; + %End + %If (Qt_4_3_0 -) +-// QList > is implemented as a Python list of 2-element tuples. +-template +-%MappedType QList > ++// QList > is implemented as a Python list of 2-element tuples. ++template ++%MappedType QList > + { + %TypeHeaderCode + #include +@@ -408,7 +408,7 @@ + // Set the list elements. + for (int i = 0; i < sipCpp->size(); ++i) + { +- const QPair &p = sipCpp->at(i); ++ const QPair &p = sipCpp->at(i); + TYPE *t = new TYPE(p.second); + PyObject *pobj; + +@@ -447,12 +447,12 @@ + return 1; + } + +- QList > *ql = new QList >; ++ QList > *ql = new QList >; + + for (int i = 0; i < PyList_GET_SIZE(sipPy); ++i) + { + PyObject *tup = PyList_GET_ITEM(sipPy, i); +- double d; ++ float d; + int state; + + d = PyFloat_AsDouble(PyTuple_GET_ITEM(tup, 0)); +@@ -466,7 +466,7 @@ + return 0; + } + +- ql->append(QPair(d, *t)); ++ ql->append(QPair(d, *t)); + + sipReleaseInstance(t, sipClass_TYPE, state); + } +@@ -524,8 +524,8 @@ + return sipGetState(sipTransferObj); + %End + }; +-// QList is implemented as a Python list of floats. +-%MappedType QList ++// QList is implemented as a Python list of floats. ++%MappedType QList + { + %TypeHeaderCode + #include +@@ -561,7 +561,7 @@ + if (sipIsErr == NULL) + return PyList_Check(sipPy); + +- QList *ql = new QList; ++ QList *ql = new QList; + + for (int i = 0; i < PyList_GET_SIZE(sipPy); ++i) + ql->append(PyFloat_AsDouble(PyList_GET_ITEM(sipPy, i))); +diff -urNad python-qt4-4.3~/sip/QtCore/qvector.sip python-qt4-4.3/sip/QtCore/qvector.sip +--- python-qt4-4.3~/sip/QtCore/qvector.sip 2007-09-02 00:35:50.000000000 +0200 ++++ python-qt4-4.3/sip/QtCore/qvector.sip 2007-09-02 00:35:53.000000000 +0200 +@@ -143,8 +143,8 @@ + return sipGetState(sipTransferObj); + %End + }; +-// QVector is implemented as a Python list of floats. +-%MappedType QVector ++// QVector is implemented as a Python list of floats. ++%MappedType QVector + { + %TypeHeaderCode + #include +@@ -180,7 +180,7 @@ + if (sipIsErr == NULL) + return PyList_Check(sipPy); + +- QVector *ql = new QVector; ++ QVector *ql = new QVector; + + for (int i = 0; i < PyList_GET_SIZE(sipPy); ++i) + ql->append(PyFloat_AsDouble(PyList_GET_ITEM(sipPy, i))); +@@ -190,9 +190,9 @@ + return sipGetState(sipTransferObj); + %End + }; +-// QVector > is implemented as a Python list of 2-element tuples. ++// QVector > is implemented as a Python list of 2-element tuples. + template +-%MappedType QVector > ++%MappedType QVector > + { + %TypeHeaderCode + #include +@@ -209,7 +209,7 @@ + // Set the list elements. + for (int i = 0; i < sipCpp->size(); ++i) + { +- const QPair &p = sipCpp->at(i); ++ const QPair &p = sipCpp->at(i); + TYPE *pt = new TYPE(p.second); + PyObject *pobj; + +@@ -248,14 +248,14 @@ + return 1; + } + +- QVector > *qv = new QVector >; ++ QVector > *qv = new QVector >; + + for (int i = 0; i < PyList_GET_SIZE(sipPy); ++i) + { + PyObject *tup = PyList_GET_ITEM(sipPy, i); + int state; + TYPE *s; +- QPair p; ++ QPair p; + + p.first = PyFloat_AsDouble(PyTuple_GET_ITEM(tup, 0)); + +diff -urNad python-qt4-4.3~/sip/QtGui/qbrush.sip python-qt4-4.3/sip/QtGui/qbrush.sip +--- python-qt4-4.3~/sip/QtGui/qbrush.sip 2007-09-02 00:35:50.000000000 +0200 ++++ python-qt4-4.3/sip/QtGui/qbrush.sip 2007-09-02 00:35:53.000000000 +0200 +@@ -138,7 +138,7 @@ + + QDataStream &operator>>(QDataStream &, QBrush & /Constrained/); + QDataStream &operator<<(QDataStream &, const QBrush & /Constrained/); +-typedef QVector > QGradientStops; ++typedef QVector > QGradientStops; + + class QGradient + { +diff -urNad python-qt4-4.3~/sip/QtGui/qgraphicsitemanimation.sip python-qt4-4.3/sip/QtGui/qgraphicsitemanimation.sip +--- python-qt4-4.3~/sip/QtGui/qgraphicsitemanimation.sip 2007-09-02 00:35:50.000000000 +0200 ++++ python-qt4-4.3/sip/QtGui/qgraphicsitemanimation.sip 2007-09-02 00:35:53.000000000 +0200 +@@ -64,19 +64,19 @@ + + public: + %If (Qt_4_3_0 -) +- QList > posList() const; ++ QList > posList() const; + %End + %If (Qt_4_3_0 -) +- QList > rotationList() const; ++ QList > rotationList() const; + %End + %If (Qt_4_3_0 -) +- QList > translationList() const; ++ QList > translationList() const; + %End + %If (Qt_4_3_0 -) +- QList > scaleList() const; ++ QList > scaleList() const; + %End + %If (Qt_4_3_0 -) +- QList > shearList() const; ++ QList > shearList() const; + %End + + private: +diff -urNad python-qt4-4.3~/sip/QtGui/qpainterpath.sip python-qt4-4.3/sip/QtGui/qpainterpath.sip +--- python-qt4-4.3~/sip/QtGui/qpainterpath.sip 2007-09-02 00:35:50.000000000 +0200 ++++ python-qt4-4.3/sip/QtGui/qpainterpath.sip 2007-09-02 00:35:53.000000000 +0200 +@@ -194,8 +194,8 @@ + void setCurveThreshold(qreal threshold); + qreal curveThreshold() const; + void setDashPattern(Qt::PenStyle); +- void setDashPattern(const QVector &dashPattern); +- QVector dashPattern() const; ++ void setDashPattern(const QVector &dashPattern); ++ QVector dashPattern() const; + QPainterPath createStroke(const QPainterPath &path) const; + %If (Qt_4_3_0 -) + void setDashOffset(qreal offset); +diff -urNad python-qt4-4.3~/sip/QtGui/qpen.sip python-qt4-4.3/sip/QtGui/qpen.sip +--- python-qt4-4.3~/sip/QtGui/qpen.sip 2007-09-02 00:35:50.000000000 +0200 ++++ python-qt4-4.3/sip/QtGui/qpen.sip 2007-09-02 00:35:53.000000000 +0200 +@@ -91,8 +91,8 @@ + void setCapStyle(Qt::PenCapStyle pcs); + Qt::PenJoinStyle joinStyle() const; + void setJoinStyle(Qt::PenJoinStyle pcs); +- QVector dashPattern() const; +- void setDashPattern(const QVector &pattern); ++ QVector dashPattern() const; ++ void setDashPattern(const QVector &pattern); + qreal miterLimit() const; + void setMiterLimit(qreal limit); + bool operator==(const QPen &p) const; +diff -urNad python-qt4-4.3~/sip/QtGui/qtextoption.sip python-qt4-4.3/sip/QtGui/qtextoption.sip +--- python-qt4-4.3~/sip/QtGui/qtextoption.sip 2007-09-02 00:35:50.000000000 +0200 ++++ python-qt4-4.3/sip/QtGui/qtextoption.sip 2007-09-02 00:35:53.000000000 +0200 +@@ -62,8 +62,8 @@ + typedef QFlags Flags; + QFlags flags() const; + qreal tabStop() const; +- void setTabArray(QList tabStops); +- QList tabArray() const; ++ void setTabArray(QList tabStops); ++ QList tabArray() const; + void setUseDesignMetrics(bool b); + bool useDesignMetrics() const; + void setAlignment(Qt::Alignment aalignment); -- cgit v1.2.3