Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Qt Quick PinchHandler scale bounds don't work



  • I try to use PinchHandler in QtQuick 2.15 (macOS). But properties minimumScale and maximumScale doesn't work properly. The target's Item scale is going out of bounds each time.

    Any ideas how to make it work? Here's code sample:

    import QtQuick 2.15
    
    Item {
        Rectangle{
            color: "blue"
            anchors.fill: parent
            Rectangle{
                x: 10
                y: 10
                height: 10
                width: 10
                PinchHandler{
                    minimumScale: 0.5
                    maximumScale: 2
    
                }
            }
        }
    }
    

Log in to reply