here my specific code for the vertical resize:
Qt Code:
  1. void bottom_resize(){
  2. QRectF r=rect();
  3. r.setBottom(event->pos().y());
  4. setRect(r);
  5. scene()->update();
  6. }
To copy to clipboard, switch view to plain text mode 

How can I mantein the local coordinate (0,0) on the centre of my resized item???