On Wednesday 27 January 2016, Uwe Rathmann wrote: > Hi all, > > I'm trying to create an application with several QOpenGLWidgets ( no > regular QWidgets involved ), where some of them are on top of others. > > My first results are promising, but I couldn't find out how to enable a > transparent background for the widgets on top. I would like to have a > similar effect as with setAutoFillBackground( false ) - seeing pixels > from the widget below. > > But I also couldn't get setAutoFillBackground(true) working and had to > fill widgets myself in paintGL(). As it is explicitly mentioned in > the docs ( http://doc.qt.io/qt-5/qopenglwidget.html ) I guess it > is something wrong on my side. > > When having a regular widget on top of a QOpenGLWidget everything works > like expected, but with QOpenGLWidget the background is always black. > > Has someone ever tried this or knows if it is possible to set up > QOpenGLWidget not drawing a background at all ? > Yes it is somewhat possible. We configured it to work in QtWebEngineView, look in render_widget_host_view_qt_delegate.cpp
According to the comment there, it apparently required setting WA_AlwaysStackOnTop. `Allan _______________________________________________ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest