[PyQt] Unable to figure out error in PolygonItem.setTransformPoint()

Manoj Kumar manojkumarsivaraj334 at gmail.com
Wed Jan 30 13:58:26 GMT 2013


Hello,

    I was trying to build a small UI using PyQt . It has a window , a
button(Rotate) , and a polygon(rectangle) in a QGraphicsView. One aim of
the app is to allow the user to rotate the polygon. That is after the
button is clicked and the user clicks at a point , the nearest vertex
automatically shifts or tilts towards the user click. Ive also set the
polygon to be movable before the click and not movable after the click. The
problem is if the user moves the polygon and then clicks , the polygon
rotates in a weird manner. Could someone help me figure out the error?

Here is the link to my code:
http://pastebin.com/SqjaHjt5


-- 
Regards,
Manoj Kumar,
Mech Undergrad.
BPGC
Blog <http://manojbits.wordpress.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20130130/88114ee8/attachment.html>


More information about the PyQt mailing list