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

Graphical effects glitches after changing window visibility

    XMLWordPrintable

Details

    • Bug
    • Status: Reported
    • P2: Important
    • Resolution: Unresolved
    • 5.15.5
    • None
    • None
    • I've checked it on Linux but I also have the confirmation this happens on Windows with a different hardware configuration.
    • All

    Description

      Sometimes graphical effects draws incorrectly after changing window visibility.
      Here's minimal reproducible example:

      import QtGraphicalEffects 1.15
      import QtQuick 2.15
      import QtQuick.Controls 2.15
      import QtQuick.Window 2.15
      
      Item {
          anchors.fill: parent
          property bool firstVisible: true
          Window {
              visible: firstVisible
              width: 400
              height: 300
              color: "#ff0000"
              MouseArea {
                  anchors.fill: parent
                  onClicked: {
                      firstVisible = !firstVisible
                  }
              }
          }
          Window {
              visible: !firstVisible
              width: 400
              height: 400
              color: "#00ff00"
              Popup {
                  width: parent.width / 2
                  height: parent.height / 2
                  parent: Overlay.overlay
                  anchors.centerIn: parent
                  modal: true
                  dim: true
                  visible: !firstVisible
                  MouseArea {
                      anchors.fill: parent
                      onClicked: firstVisible = !firstVisible
                  }
              }
          }
      }
      

      This has to be viewed with Material style, for example when using with qmlscene one has to pass

      -style Material
      

      (and ignore the warning).

      Steps to reproduce: click to the visible window several times (usually <20)

      Effect:

      Expected:

      With glitches:

      I haven't found any workaround for this - requesting update after the window gets visible doesn't help. When you have more than one popup, it always makes a glitches all or none at the time.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            qt.team.graphics.and.multimedia Qt Graphics Team
            jaskmar Mariusz Jaskółka
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes