Nevermind, I figured it out. Instead of adding d_plot directly to the horizontalLayout, I added it to QwtDynGridLayout first, and then added the layout to the horizontalLayout:

Qt Code:
  1. gLayout = new QwtDynGridLayout(this);
  2. gLayout->addWidget(d_plot);
  3. ui.horizontalLayout->insertLayout(0, gLayout);
To copy to clipboard, switch view to plain text mode 

Now I get a square