Debilitating regression bug in 4.8.x


    We rely heavily on QListWidget to have real-live widgets with complex controls as rows. We cannot implement this complex row design with QListView and delegates. T

    The effect is there is no scrolling in Mac. Scrollbar has no effects on the viewport. It won't scroll it. Nor will the mouse 'wheel'.

    This is a showstopper for us and our Application.

    how do we even begin to tackle that?

  • Three options:

    • Don't use Qt 4.8 while you wait for someone else to fix the problem
    • Fix the problem in Qt 4.8 and submit the patch
    • Try Qt 5. I don't know, it may be fixed there.

    I am, of course, assuming you do not have commercial support.

    Alternatively, since you want a vertical scrolling list of widgets, it seems that a QScrollArea with a QWidget container and QVBoxLayout could have a similar function.

  • Unfortunately, the problem is still there, even with Qt 5.0.1
    It works well in 4.7.4, and unfortunately I had to revert to that version.

    It's a pity. And yes, I am a commercial customer but nothing from their support yet. I guess they're as puzzled as I am as to why they broke it so many versions ago and never got around to fix this or even relate to the bug report that's sitting there for so long.

  • Even if commercial support is puzzled they should be communicating that to you so you don't have to guess. Perhaps it is time to poke the support people again?

  • I am happy to report a workaround patch for suggested by Qt-commercial support, applied and seems to be working for my Qt 4.8.5. I'll go post it onto the bug report to help all those who are still struggling. I replaced the "@@" strings in the patch with "^^" for formatting purposes.

    --- /Users/irfanomair/dev/qt-src-carbon-4.8.0/src/gui/kernel/ 2011-12-15 10:38:21.000000000 -0800
    +++ kernel/ 2012-09-18 17:17:03.000000000 -0700
    ^^ -1,22 +1,41 ^^

    ^^ -4684,15 +4703,14 ^^

     // Scroll the whole widget if qscrollRect is not valid:
    • QRect validScrollRect = qscrollRect.isValid() ? qscrollRect : q->rect();
    • validScrollRect &= clipRect();
    • QRect validScrollRect = qscrollRect.isValid() ? qscrollRect : QRect(0, 0, q->width(), q->height());

      // If q is overlapped by other widgets, we cannot just blit pixels since
      // this will move overlapping widgets as well. In case we just update:
      const bool overlapped = isOverlapped(validScrollRect.translated(data.crect.topLeft()));
      const bool accelerateScroll = accelEnv && isOpaque && !overlapped;
      const bool isAlien = (q->internalWinId() == 0);

    • const QPoint scrollDelta(dx, dy);
     // If qscrollRect is valid, we are _not_ supposed to scroll q's children (as documented).
     // But we do scroll children (and the whole of q) if qscrollRect is invalid. This case is

    ^^ -4714,7 +4732,6 ^^
    }else {

    •    return;

    #ifdef QT_MAC_USE_COCOA
    ^^ -4731,6 +4748,7 ^^
    // moved when the parent is scrolled. All directly or indirectly moved
    // children will receive a move event before the function call returns.
    QWidgetList movedChildren;

    • const QPoint scrollDelta(dx, dy);
      if (scrollChildren) {
      QObjectList children = q->children();


Log in to reply

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.