I draw few objects and connections between them. All objects are subclassed from QGraphicsWidget.
If I scroll view so that part of grey rectangle is not visible - then all lines/connections are gone. Lines/Connections are set as children to those rectangles.
The same situation with lines between rectangles. There's one big QGraphicsWidget set as parent for them and used to expand view - this big widget is a parent for lines/connections between rectangles. And they disappear too.
For me it looks like some kind clipping.

That's how I paint rectangles (smaller one have different colour) .
Qt Code:
  1. QColor cGray(Qt::gray);
  2. cGray = cGray.light();
  3. QBrush brush(cGray);
  4. painter->setBrush(brush);
  5. painter->drawRect(0,0,size().width(),size().height());
To copy to clipboard, switch view to plain text mode 

And connections/lines.
Qt Code:
  1. QPen stPen;
  2. stPen.setWidth(2);
  3. painter->setPen(stPen);
  4. painter->drawLines(m_vPathLines);
To copy to clipboard, switch view to plain text mode 

Params set for QGraphicsView
Qt Code:
  1. m_ptrSceneView = new QGraphicsView;
  2. m_ptrSceneView->setInteractive(true);
  3. m_ptrSceneView->setDragMode(QGraphicsView::ScrollHandDrag);
  4. m_ptrSceneView->setScene(&m_RP3Scene);
  5. m_ptrSceneView->setViewportUpdateMode(QGraphicsView::FullViewportUpdate);
To copy to clipboard, switch view to plain text mode 





Could some one tell me - how to set this Graphics Environment, so lines/connections won't disappear when I scroll?