Is this intended, or shall I file a bug ? I really spent hours to trace why I was not able to place the titem_title QGraphicsTextItem at the proper position (decorating my items).

Hope it helps others and here is code that circumvents this limitation.

Qt Code:
  1. void
  2. QGraphicsItemGroupDERIVED::update()
  3. {
  4. #define CERRD std::Cerr
  5.  
  6. this->removeFromGroup( this->titem_title );
  7.  
  8. QTransform t;
  9.  
  10. t.setMatrix( this->transform().m11(), this->transform().m12(), 0, 0, 0, 0, 0, 0, 0 );
  11.  
  12. this->titem_title->setTransform( t );
  13.  
  14. this->titem_title->setPos( this->sceneBoundingRect().topLeft() );
  15.  
  16. this->addToGroup( this->titem_title );
  17.  
  18.  
  19.  
  20. CERRD << endl << "ITEM = " << this->name_get().toStdString() << endl;
  21.  
  22. if( this->titem_title->sceneBoundingRect().topLeft() != this->sceneBoundingRect().topLeft() )
  23. {
  24. CERRD << "*** WARNING *** setPos on titem failed." << endl;
  25. }
  26.  
  27. CERRD << "item actualpos = " << this->sceneBoundingRect().topLeft() << endl;
  28. CERRD << "titem_title actualpos = " << titem_title->sceneBoundingRect().topLeft() << endl;
  29. }
To copy to clipboard, switch view to plain text mode 

Cheers,
Murat