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

Slider with negative width crash the application

    XMLWordPrintable

    Details

    • Platform/s:
      Windows
    • Commits:
      ca54be7882ad1cdce59b30146abd8bdb6f464298 (qt/qtdeclarative/6.2) e9bdafcfad0f09d15b710a3bca5acae2604c14bc (qt/qtdeclarative/dev)

      Description

      If a Slider has a negative width, the application crash.

      Here is the code to reproduce:

      import QtQuick
      import QtQuick.Window
      import QtQuick.Controls
      
      Window {
          width: 640
          height: 480
          visible: true
          title: qsTr("Hello World")
      
          Slider {
              width: -100
      
          }
      }
      

      The workaround is to add a condition to the visible property:

      visible: width > 0

        Attachments

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

          Activity

            People

            Assignee:
            vhilshei Volker Hilsheimer
            Reporter:
            remy67 remy rouvin
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes