Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-37852

Child widgets not repainted with WA_OpaquePaintEvent set on parent

    XMLWordPrintable

Details

    • a7e8b400d1ca6cf4e23b02564812ea3ff0bb9015

    Description

      The attribute WA_OpaquePaintEvent has different behavior in Qt5.3 from previous versions.

      Let's say you have a widget that draws a fancy background. It does not need any Qt or system provided background, so it sets WA_OpaquePaintEvent. But it also has one or more child widgets.

      In Qt 5.3.0 Beta1, an update() or repaint() on the parent widget does not redraw any of the child widgets. They disappear.

      In previous versions, the child widgets would redraw.

      I've attached a sample project that illustrates it.

      When you run the program, press '0' to repaint the parent (and see the child widgets disappear), or press '1', '2' or '3' to repaint the child widgets.

      Attachments

        1. OpaquePaint.zip
          5 kB
          Dyami Caliri
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            sorvig Morten Sørvig
            dzedsystems Dyami Caliri
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes