PDA

View Full Version : QPolygonF preview for a custom QGraphicsItem



matteo.boscolo
14th July 2010, 17:47
Hi All,
I'm trying to create a painter.drawPolyline passing a QpoligonF as argument.

I Try to make a preview of the polyline object .

I got a strange beavior..

It seems that the point sequence that the painter use is different from the one I give

This is my array:
point PyQt4.QtCore.QPointF(92.984541726000003, -5.6568542494900003)
point PyQt4.QtCore.QPointF(95.105862069599993, -92.277434944800007)
point PyQt4.QtCore.QPointF(2.1213203435599999, -91.923881554299996)
point PyQt4.QtCore.QPointF(90.863221382471338, 21.213203435596419) <- this is the mouse move

this is the sequence that the qtpainter render on drawPolyline (the list cam from what i see on the screen)

point PyQt4.QtCore.QPointF(95.105862069599993, -92.277434944800007)
point PyQt4.QtCore.QPointF(90.863221382471338, 21.213203435596419) <- this is the mouse move
point PyQt4.QtCore.QPointF(2.1213203435599999, -91.923881554299996)

Any help ?

Regards,
Matteo

matteo.boscolo
16th July 2010, 16:04
Solved it was a my programming mistakes ..
:)