title: How can I maximize my main window and prevent resize in QT
body: <p>I am trying to maximize my main qt window upon running and prevent the user from resizing it. I have tried </p>
  
  <pre><code>int main(int argc, char *argv[])
  {
      QApplication a(argc, argv);
      MainWindow widget;
      widget.showMaximized();
      widget.show();
      return a.exec();
  }
  </code></pre>
  
  <p>Which does maximize the window, along with </p>
  
  <pre><code>MainWindow::MainWindow(QWidget *parent) :
      QMainWindow(parent),
      ui(new Ui::MainWindow)
  {
      this-&gt;setWindowFlags(this-&gt;windowFlags() | Qt::MSWindowsFixedSizeDialogHint);
      ui-&gt;setupUi(this);
  }
  </code></pre>
  
  <p>which does grey out the "restore down", "maximize" button located in the title bar in the middle of minimize and close window. </p>
  
  <p>But I am still able to drag the title bar down to unsnap the maximized window and then readjust the size with the corner and edges. </p>
  
  <p>How can I prevent the ability to unsnap the window and no strictly no resizing. </p>
  
  <p>Thanks!</p>