PDA

View Full Version : Make QPainter paint above all widgets



Grzyboo
8th August 2015, 02:11
How to make QPainter draw above all widgets?

ChrisW67
8th August 2015, 02:48
What do you mean by "above"?

Grzyboo
8th August 2015, 13:17
Treat every widget as a layer. Red rectangles are shapes drawn with QPainter, the rest are widgets. QPainter draws everything on the window's layer, beneath all widgets. How to make widgets not cover my red rectangles?
11311

anda_skoa
8th August 2015, 13:31
Maybe: in the paint event handler of your window, first call the base implementation, then draw yourself.

Cheers,
_

TPS
3rd November 2015, 15:04
Hello Grzyboo,

Did you find the solution to your question ?
Even I am interested in the same.
It would be great if you or someone else can help.

Thanks.

ChrisW67
3rd November 2015, 19:37
Anda_skoa had a good hint.
You should also consider if QGraphicsView is a better approach to your particular problem.