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

QtQuick.Controls 2 ToolBar memory leak when resizing

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P2: Important
    • None
    • 5.7.0, 5.7.1, 5.8.0
    • None
    • OS: Windows 10 Home
      CPU: Intel Core i7-5700HQ
      GPU: Nvidia GeForce GTX 970M
      RAM: 16 Gb

      Qt Creator v4.2.1
      Qt 5.7.0 for MSVC2013 64bit
      Qt 5.8.0 for MSVC2015 64bit

    Description

      There is a huge memory leak in the ToolBar from QtQuick.Controls2 when choosing Material theme.

      How to reproduce:
      Create an ApplicationWindow, put ToolBar into it's header, set Material theme in qtquickcontrols2.conf. Now launch your application and try to resize the window. Memory consumption will start to grow very fast.

      I think this issue related only to Windows, because my colleague could not reproduce it on Linux.

      UPDATE:
      I have found that the actual problem is buggy DropShadow effect.
      It is attached to the ToolBar when using Material theme, but setting Material.elevation to 0 fixes memory leak (but removes shadow effect).
      Adding DropShadow effect to the scene manually also causes huge memory leak on window resize. See updated main.qml.

      Attachments

        1. main.qml
          0.4 kB
        2. main.qml
          0.1 kB
        3. qml.qrc
          0.1 kB
        4. qtquickcontrols2.conf
          0.0 kB
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            sletta Gunnar Sletta
            victorzs Victor Zarubkin
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes