Qt/X11: How to make a QWidget override-redirect / calling XChangeWindowAttributes() with QWidget

非 Y 不嫁゛ 提交于 2019-12-10 20:45:49

问题


Does anybody has an example how to make a QWidget instance (as toplevel window) override-redirect with the X11 library? the following code doesn't work:

        QWidget* widget = new QWidget();
        XSetWindowAttributes attr;
        attr.override_redirect = true;
        XChangeWindowAttributes(display, widget->winId(), CWOverrideRedirect, &attr);
        widget->show();

Does anybody has an idea? The bigger toplevel-problem i try to solve is the following: QWidget / X11: Prevent window from beeing activated/focussed by mouse clicks

Thank you very much in advance! Frime

来源:https://stackoverflow.com/questions/29209462/qt-x11-how-to-make-a-qwidget-override-redirect-calling-xchangewindowattribute

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!