Custom Widget in QScrollArea Badly Redrawing Only on Scroll
问题 I'm trying to get a custom scrolling widget in QT, and I'm getting redraw errors on scroll. Alt-tab or other redrawing events redraw correctly. I'm basing it on the example at http://doc.qt.io/qt-5/qtwidgets-widgets-charactermap-example.html repeatingwidget.cpp (excerpt): QSize RepeatingWidget::sizeHint() const { return QSize(500, itemHeight * displayItems.size() + 1); } void RepeatingWidget::paintEvent(QPaintEvent *event) { QPainter painter(this); painter.fillRect(event->rect(), QBrush(Qt: