The background of the QMdiArea is not redrawn (cleared) when I resize a plot where I have synchronized axes. Traces of the old window are left in the background when I reduce the plotwindow.

I use MdiChilds that inherit from QCustomPlot -

class MdiChild : public QCustomPlot

The glitch only appears, when I connect the plots to synchronize, which I do in the following way:

      connect(child_bef->xAxis, SIGNAL(rangeChanged(QCPRange)),
              child->xAxis, SLOT(setRange(QCPRange)));
      connect(child_bef, SIGNAL(beforeReplot()), child, SLOT(replot()));


      connect(child->xAxis, SIGNAL(rangeChanged(QCPRange)),
              child_bef->xAxis, SLOT(setRange(QCPRange)));
      connect(child, SIGNAL(beforeReplot()), child_bef, SLOT(replot()));

It happens with resize only, not with draggin the plot. I also tried "afterReplot" instead of "beforeReplot" without success.