System styles such as those from Windows and macOS ignore certain hints and draw controls as expected for these platforms. Qt follows the platform user interface guidelines closely to ensure that applications looks as expected.
Well to get below the QWTPlot plot would
be QWTPlotptr->y() + QWTPlotptr->height()
However, a more solid approach could be to use a QLabel as
a canvas using a pixmap. That way, its very easy to position even if using layouts to make
GUI auto adjust to different screen sizes.
// take size of label
int h = ui->label->height();
int w = ui->label->width();
// make a pixmap of the wanted size
QPixmap pix(w, h);
// assign painter to it so we can paint on it
// fill it
pix.fill( Qt::white );
// paint on canvas
paint.setPen(QColor(0, 0, 0, 255));
paint.drawRect(0, 0, w, h);
..other paint operations-..
// set the pixmap to the label so its shown.
After further investigation, it appears that this is because I am using OpenGL - the 'fullUpdate' flag in updateScene is always set in this case - qgraphicsView has "accelerateScrolling = !isGlWidget" [in setupViewport, line 2759] and "fullUpdate = !d->accelerateScrolling" [in updateScene, line 2675]
so if I prefer 16ms, that will make the cursor move 8 pixels each 16ms, which is maybe too jolting to see ...
It's not a question of preference. It's a hardware constraint. paintEvent won't happen more often that the hardware allows. It's not that you shouldn't update more often. It's physically impossible (unless you've got a high-frequency display, which very few people do).