Re: [PyQt] issue with QPainter.drawPolyline and list of QPoints

2012-02-01 Thread Hans-Peter Jansen
On Wednesday 01 February 2012, 09:57:35 Phil Thompson wrote: > On Wed, 1 Feb 2012 01:25:57 +0100, "Hans-Peter Jansen" > > > wrote: > > Hi Phil, > > > > shouldn't this work: > > > > from PyQt4 import QtCore, QtGui > > app = QtGui.QApplication([]) > > pixmap = QtGui.QPixmap(16, 16) > > painter = QtG

Re: [PyQt] issue with QPainter.drawPolyline and list of QPoints

2012-02-01 Thread Phil Thompson
On Wed, 1 Feb 2012 01:25:57 +0100, "Hans-Peter Jansen" wrote: > Hi Phil, > > shouldn't this work: > > from PyQt4 import QtCore, QtGui > app = QtGui.QApplication([]) > pixmap = QtGui.QPixmap(16, 16) > painter = QtGui.QPainter(pixmap) > plist = [QtCore.QPoint(0, 15), QtCore.QPoint(0, 0), QtCore.QP

[PyQt] issue with QPainter.drawPolyline and list of QPoints

2012-01-31 Thread Hans-Peter Jansen
Hi Phil, shouldn't this work: from PyQt4 import QtCore, QtGui app = QtGui.QApplication([]) pixmap = QtGui.QPixmap(16, 16) painter = QtGui.QPainter(pixmap) plist = [QtCore.QPoint(0, 15), QtCore.QPoint(0, 0), QtCore.QPoint(15, 0)] painter.drawPolyline(plist) With PyQt 4.9, this results in: TypeEr