[PyKDE] How to pass the QMemArray<type> object??

Phil Thompson phil at riverbankcomputing.co.uk
Thu Feb 26 20:00:01 GMT 2004


On Thursday 26 February 2004 09:52, Jacob Abraham wrote:
> Dear Tutors,
>    I would like to use this funtion in pyqt and came
> across the following problems.
> void QTable::removeRows ( const QMemArray<int> & rows
> )
>
> 1.
> from qt import QMemArray
> ImportError: cannot import name QMemArray
> 2.
> mylist=[5]
> self.mytable.removeRows(mylist)
>
> QGArray::at: Absolute index 0 out of range
> Segmentation fault
>
> """
> #http://www.riverbankcomputing.co.uk/pyqt/docs/PyQt.html#AEN668
> QMemArray<type> (Qt v3+)
>
> Types based on the QMemArray template are
> automatically converted to and from Python lists of
> the type.
> """
>     How do I pass the QMemArray Object to the
> removeRows funtion?

Looks like a bug. Can you apply the attached patch and re-build PyQt.

Phil
-------------- next part --------------
A non-text attachment was scrubbed...
Name: qmemarray.sip.patch
Type: text/x-diff
Size: 285 bytes
Desc: not available
Url : http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20040226/e4f7184c/qmemarray.sip.bin


More information about the PyQt mailing list