I have created a Qt application with the following structure:
*
Qt Code:
  1. .
  2. └── QMdiArea
  3. * * └── QTabWidget
  4. * * * * └── HeaderDataBrowser
  5. * * * * * * └── QVBoxLayout
  6. * * * * * * * * └── QSplitter
  7. * * * * * * * * * * ├── QScrollArea1
  8. * * * * * * * * * * │ * └── QVBoxLayout
  9. * * * * * * * * * * │ * * * └── QTreeWidget
  10. * * * * * * * * * * └── QScrollArea2
  11. * * * * * * * * * * * * └── QVBoxLayout
  12. * * * * * * * * * * * * * * ├── QwtPlot1
  13. * * * * * * * * * * * * * * └── QwtPlot2
To copy to clipboard, switch view to plain text mode 

I'm having multiple issues.
1) It appears the parent widgets of the QwtPlot widgets are ignoring the minimum size constraints. The plots just start overlapping when things get small.
2) Even though the QwtPlot widgets are inside a QScrollArea, no scrollbars ever appear, even when resizing ridiculously small. Why?
3) Issue 1) applies to a lot of the other parent widgets. They just ignore the minimum size constraints of their child widgets.

*
This video demonstrates the issues I'm having.
1) The first run shows that the app can be scaled right down to a size that shouldn't be possible.
2) I then set the minimum size of both QwtPlot widgets to 200, 200. Now the plots don't resize smaller than 200, 200, but they begin overlapping each other. What I really want is to restrict the app's minimum size so that doesn't happen.
3) I then set the minimum size of the splitter widget to 300, 300 and show that the parent widgets of the application simply do not care. The scroll area gets clipped as the application is scaled down.
*

*
The following code replicates this behaviour (note: I'm running Qt5. Qt4 seems to have different behaviour for some reason):

Qt Code:
  1. #include "mainwindow.h"
  2. #include "ui_mainwindow.h"
  3.  
  4. #include <QVBoxLayout>
  5. #include <QMdiArea>
  6. #include <QSplitter>
  7. #include <QScrollArea>
  8. #include <QTreeWidget>
  9.  
  10. MainWindow::MainWindow(QWidget *parent) :
  11. QMainWindow(parent),
  12. ui(new Ui::MainWindow)
  13. {
  14. ui->setupUi(this);
  15.  
  16. ui->centralWidget->setLayout(new QVBoxLayout);
  17. QMdiArea* mdi = new QMdiArea;
  18. ui->centralWidget->layout()->addWidget(mdi);
  19.  
  20. QTabWidget* tabWidget = new QTabWidget;
  21. mdi->addSubWindow(tabWidget);
  22. tabWidget->showMaximized();
  23.  
  24. QWidget* headerDataBrowser = new QWidget;
  25. tabWidget->addTab(headerDataBrowser, "Header");
  26.  
  27. // Header data tree goes on the left side, TxSeq plots on the right
  28. QVBoxLayout* browserLayout = new QVBoxLayout;
  29. QSplitter* splitter = new QSplitter(headerDataBrowser);
  30. browserLayout->addWidget(splitter);
  31. headerDataBrowser->setLayout(browserLayout);
  32.  
  33. // Create scroll area and put a tree view inside it. Then add the scroll
  34. // area to the left side of the splitter
  35. QScrollArea* scroll = new QScrollArea;
  36. scroll->setWidgetResizable(true);
  37. splitter->addWidget(scroll);
  38. QVBoxLayout* scrollLayout = new QVBoxLayout;
  39. scroll->setLayout(scrollLayout);
  40. QTreeWidget* treeWidget = new QTreeWidget;
  41. scrollLayout->addWidget(treeWidget);
  42.  
  43. // Create layout on right side of splitter. This is where the plots are
  44. // inserted. Also add it to a scroll area, but disable horizontal
  45. // scrolling.
  46. QScrollArea* plotArea = new QScrollArea;
  47. //plotArea->setWidgetResizable(true);
  48. //plotArea->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOf f);
  49. splitter->addWidget(plotArea);
  50. QVBoxLayout* plotLayout = new QVBoxLayout;
  51. plotArea->setLayout(plotLayout);
  52.  
  53. // add some crap
  54. for(int i = 0; i != 20; ++i)
  55. (new QTreeWidgetItem(treeWidget))->setText(0, "Test " + QString::number(i));
  56. }
  57.  
  58. MainWindow::~MainWindow()
  59. {
  60. delete ui;
  61. }
To copy to clipboard, switch view to plain text mode 
*