Re: [Interest] How to change parent of scaled QGraphicsItem while retaining scene bounding rect?

2018-08-08 Thread Patrick Stinson
I got a little further, this snippet works when the parent items don’t have a scale set. But when the parents do have a scale set the child item’s position jumps around a bit when changing parents. def setParent(parent): if parent == child.parentItem(): return if

Re: [Interest] How to change parent of scaled QGraphicsItem while retaining scene bounding rect?

2018-08-08 Thread Patrick Stinson
Thanks for that. Though I am having some trouble. If you have PyQt, I wonder what problem you see with this example: def tests_QGI_parent_transform(): app = QApplication(sys.argv) view = QGraphicsView() scene = QGraphicsScene() rect = QRectF(-50.0, -50.0, 100.0, 100.0) paren

Re: [Interest] How to change parent of scaled QGraphicsItem while retaining scene bounding rect?

2018-08-07 Thread Christian Gagneraud
On 8 August 2018 at 15:49, Patrick Stinson wrote: > Thanks for the reply. I am just particularly dense in this sort of cognitive > operation (something about flipping symbolic representations like in > fractional arithmetic) and might do well with just a bit of code or pseudo > code. Do you thi

Re: [Interest] How to change parent of scaled QGraphicsItem while retaining scene bounding rect?

2018-08-07 Thread Patrick Stinson
Thanks for the reply. I am just particularly dense in this sort of cognitive operation (something about flipping symbolic representations like in fractional arithmetic) and might do well with just a bit of code or pseudo code. Do you think you might provide some? Thanks! > On Aug 7, 2018, at 6

Re: [Interest] How to change parent of scaled QGraphicsItem while retaining scene bounding rect?

2018-08-07 Thread Christian Gagneraud
On 8 August 2018 at 11:08, Patrick Stinson wrote: > Hello! > > I am trying to change the parent of a QGraphicsItem without it appearing to > move or change size on the scene. Both the item, old parent, and new have > arbitrary scale values set. How can this be done? If you grab the item's scene

[Interest] How to change parent of scaled QGraphicsItem while retaining scene bounding rect?

2018-08-07 Thread Patrick Stinson
Hello! I am trying to change the parent of a QGraphicsItem without it appearing to move or change size on the scene. Both the item, old parent, and new have arbitrary scale values set. How can this be done? Thanks! ___ Interest mailing list Interest@q