[Qt] How to copy QWidget content into QPixmap/QImage inside that QWidget paintEvent() ?

Den Jean Den.Jean at telenet.be
Wed May 20 23:40:51 CEST 2009


On Monday 18 May 2009 11:18:20 Paul Ishenin wrote:
> Imagine a situation we have a TForm canvas and we want to copy its
> content to the TBitmap canvas, then do some manipulations with TBitmap
> canvas and draw it back to the TForm canvas (example is here:

reading material:
http://doc.trolltech.com/qq/qq16-background.html
http://doc.trolltech.com/4.1/qwidget.html#transparency-and-double-buffering
http://doc.trolltech.com/qq/qq16-fader.html

in the fader example you could copy content of underlying
widget and do your transformation. 
Qwidget properties should be set for event transparency 
(Qt::WA_TransparentForMouseEvents)
(never tried this)

regards, 

Den Jean





More information about the Qt mailing list