I made a custom widget called MovieTabPane, which eventually will be inside a QTabWidget. But I've been testing it using this:

Qt Code:
  1. MovieTabPane *m = new MovieTabPane();
  2. m->show();
To copy to clipboard, switch view to plain text mode 

Which has worked fine. But now, I'm adding the QMainWindow, and trying to put the MovieTabPane on as the central widget with a QMenuBar. The entire window comes out empty except the menu bar and widget, which are cramped into the top left corner.

Here's the code:

Qt Code:
  1. ApplicationWindow()
  2. {
  3. // Create MenuBar and Connection Menu
  4. mMenuBar = new QMenuBar( this );
  5. mConnectionMenu = new QMenu( tr("&Connection"), mMenuBar );
  6. mMenuBar->addMenu( mConnectionMenu );
  7.  
  8. // Create Connect Action, and connect triggered() signal to message() <== temporary
  9. mConnectAction = new QAction( tr("Co&nnect"), mConnectionMenu );
  10. connect( mConnectAction, SIGNAL( triggered() ), this, SLOT( message() ) );
  11.  
  12. // Create Custom Widget
  13. mMovieTabPane = new MovieTabPane( this );
  14.  
  15. // Create Grid Layout and add mMovieTabPane
  16. mGridLayout = new QGridLayout( this );
  17. mGridLayout->addWidget( mMovieTabPane );
  18.  
  19. // Tell AppWindow to use mGridLayout
  20. setLayout( mGridLayout );
  21.  
  22. // Scale
  23. resize( 905, 495 );
  24.  
  25. // Show
  26. show();
  27. }
To copy to clipboard, switch view to plain text mode 

I'll be back in a few hours to check replies... gotta go write a Physics mid term