How to redraw QGraphicsScene background in running
In my QGraphicsScene object declare, I have draw a picture in drawBackground(), see below:
Code:
{
public:
MyScene(qreal x, qreal y, qreal w, qreal h)
protected:
{ //draw an old background
};
In my program running, I need redraw the background, how I will do?
Very Thanks
Re: How to redraw QGraphicsScene background in running
Call QGraphicsScene::invalidate() with QGraphicsScene::BackgroundLayer.
Re: How to redraw QGraphicsScene background in running
Thank you. But I not understand. Do you give me a particular explain or a source code
Re: How to redraw QGraphicsScene background in running
Follow the link in my post.