With wxWidgets I use the following code:
HWND main_window = ...
...
wxWindow *w = new wxWindow();
wxWindow *window = w->CreateWindowFromHWND(0, (WXHWND) main_window);
How do I do the same thing in Qt? The HWND
is the handle of the window I want as the parent window for the new QtWidget.
Use the create method of QWidget.
HWND main_window = ...
...
QWidget *w = new QWidget();
w->create((WinId)main_window);