Hi,
I would like to know is there any way to launch the application in the main window it self, instead of opening a new window.
what are the challenges in doing so, i googled and found out some sample , but its not working.

Qt Code:
  1. #include <QtGui/QApplication>
  2. #include "mainwindow.h"
  3.  
  4. int main(int argc, char *argv[])
  5. {
  6. QApplication a(argc, argv);
  7. MainWindow w;
  8.  
  9. w.show();
  10.  
  11. return a.exec();
  12. }
To copy to clipboard, switch view to plain text mode 


Qt Code:
  1. #include "mainwindow.h"
  2. #include <QProcess>
  3.  
  4. MainWindow::MainWindow(QWidget *parent)
  5. : QMainWindow(parent)
  6. {
  7. QProcess * proc = new QProcess(this);
  8. //proc->start("Artha");// -into"+QString((int)this->winId()));
  9. proc->start("Artha -into"+QString((int)parent->winId()));
  10.  
  11. }
  12.  
  13.  
  14. MainWindow::~MainWindow()
  15. {
  16.  
  17. }
To copy to clipboard, switch view to plain text mode 

Qt Code:
  1. #ifndef MAINWINDOW_H
  2. #define MAINWINDOW_H
  3.  
  4. #include <QtGui/QMainWindow>
  5.  
  6. class MainWindow : public QMainWindow
  7. {
  8. Q_OBJECT
  9.  
  10. public:
  11. MainWindow(QWidget *parent = 0);
  12. ~MainWindow();
  13. };
  14.  
  15. #endif // MAINWINDOW_H
To copy to clipboard, switch view to plain text mode