I need to include QtPlatformHeaders/QWindowsWindowFunctions
-
Hi,
I'm using Qt 6.0.2 in connection with Visual Studio 2019 and I don't know how to include QWindowsWindowFunctions (I need this to solve a OpenGL issue, see https://doc.qt.io/qt-6/windows-issues.html).
I tried #include <QtPlatformHeaders/QWindowsWindowFunctions> but it didn't work.
I couldn't even find a directory QtPlatformHeaders somewhere in the Qt folder...Do I need to install something else?
Thanks for any help!
-
Looks like it's not yet ported - stay at 5.15 until then.
-
Hi and welcome to devnet,
It might also have been moved, see this blog post.
-
Thank you very much for your answers so far!
Yes, it seems thatQWindowsWindowFunctions::setHasBorderInFullScreen
has been moved toQWindowsWindow
.
I've been trying to getusing namespace QNativeInterface::Private; if (auto *windowsWindow = dynamic_cast<QWindowsWindow*>(window->handle())) windowsWindow->setHasBorderInFullScreen(true); [...]
to work (from the blog) but I don't know exactly how:
- The class QWindowsWindow is defined in
QtGui/6.0.2/QtGui/qpa/qplatformwindow_p.h
. It seems a bit strange to include this file? - Do you know how I can get
window->handle()
from QMainWindow?
Many thank again :)
- The class QWindowsWindow is defined in
-
For my actual problem (
QMenu
not visible when using OpenGL inQMainWindow
with full screen) I found workarounds described in https://bugreports.qt.io/browse/QTBUG-41309.So I think I can close this thread, because as @Christian-Ehrlicher wrote,
QWindowsWindowFunctions
doesn`t seem to be ported properly yet.