With wxWidgets I use the following code:
HWND main_window = ... ... wxWindow *w = new wxWindow(); wxWindow *window = w->CreateWindowFromHWND(0, (WXHWND) main_win
Use the create method of QWidget.
HWND main_window = ... ... QWidget *w = new QWidget(); w->create((WinId)main_window);