Hi,

I'm trying to build a plot in a QWidget which has a background. I want to see through my plot the background of this widget.

I tried a lot of tips given by Uwe on this forum but I have never managed to have my plot fully transparent.

Here is what I tried :

With palette :
setAutoFillBackground( true );
QColor c( Qt::gray );
c.setAlpha( 50 );
QPalette pal;
pal.setColor( QPalette::Window, c );

canvas()->setPalette( pal );
canvas()->setAutoFillBackground( true );
with stylesheet :
setAutoFillBackground( true );
setStyleSheet("QwtPlot{ border: 0px; background: transparent;}");
canvas()->setStyleSheet("border: 0px; background: transparent;");
canvas()->setAutoFillBackground(false);
I must have some issues with the attribute and PaintAttribute but I can't find which one.
The best result I had was :
- axis fully transparent but canvas stays white
- all plot and canvas transparent through the parent widget itself (I can see the widgets under my parent's widget)

Thanks for your help