Changing a QMaindow's opacity doesn't seem to work whether changing the windowOpacity in Designer or by
Code:
ui(new Ui::AboutWin) { ui->setupUi(this); setAttribute(Qt::WA_DeleteOnClose); this->setWindowOpacity(0.3); }
Printable View
Changing a QMaindow's opacity doesn't seem to work whether changing the windowOpacity in Designer or by
Code:
ui(new Ui::AboutWin) { ui->setupUi(this); setAttribute(Qt::WA_DeleteOnClose); this->setWindowOpacity(0.3); }
Quoting the docs:
This feature is available on Embedded Linux, Mac OS X, Windows, and X11 platforms that support the Composite extension.
This feature is not available on Windows CE.
Note that under X11 you need to have a composite manager running, and the X11 specific _NET_WM_WINDOW_OPACITY atom needs to be supported by the window manager you are using.
This answer is not to change opacity in the constructor. Change it after the window is painted, e.g.
AboutWin *win = new AboutWin;
win->show();
win->setWindowOpacity(0.75);