Running another application within a QDockWidget
-
Does anyone know how to start another application within a QDockWidget? For example I am trying to start FlightGear within a QDockWidget. Any help on this subject would be greatly appreciated.
Phillip
-
Do you mean embedding an application window inside a QDockWidget as a normal widget, or just start it from QDockWidget in its own window?
-
Embedding an application inside a QDockWidget as a normal widget. As for starting another application from a QDockWidget I was able to accomplish this by using QProcess.
Have you ever tried to embed an application?
-
This is not something that can be answered in general.
You have to integrate the window of the started application. This depends on the platform and the used technologies if that is possible and how. On windows for example for "normal" windows, you must set the parent of the window be the dockWidget (how ever you do that :-) ). -
Tried setting the parent but the second application continues to start outside of the widget. :(
-
If you are working in a *nix like OS you can use "QX11EmbedContainer":http://qt-project.org/doc/qt-4.8/qx11embedcontainer.html.
FlightGear is the Open Source proyect, right? In such case, you can try modifying the source to do all render in a QGraphicsWidget or QGLWidget inside your application. -
QX11EmbedContainer seems to be only available for linux but I am trying to stay on a Windows platform for this project.
Do you know of an equivalent QX11EmbedContainer class for win 7?