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

Change SplitView orientation

    XMLWordPrintable

Details

    • Linux/X11, Windows

    Description

      SplitView handle is out of normal size when changing rotation of SplitView. But if you change the size, then the handle has the correct size.

      Example:

       

      Code to reproduce:

      import QtQuick 2.15
      import QtQuick.Window 2.15
      import QtQuick.Controls 2.15
      
      Window {
          width: 640
          height: 480
          visible: true
          title: qsTr("SplitView jopa")
      
          SplitView {
              id: root
              anchors.fill: parent
      
              Rectangle {
                  color: "red"
                  SplitView.preferredWidth: root.orientation === Qt.Horizontal
                                            ? root.width / root.count : root.width
                  SplitView.preferredHeight: root.orientation === Qt.Horizontal
                                             ? root.height : root.height / root.count
              }
      
              Rectangle {
                  color: "blue"
                  SplitView.preferredWidth: root.orientation === Qt.Horizontal
                                            ? root.width / root.count : root.width
                  SplitView.preferredHeight: root.orientation === Qt.Horizontal
                                             ? root.height : root.height / root.count
              }
          }
      
          Button {
              text: "ROTATE ME"
              onClicked: root.orientation = (root.orientation === Qt.Horizontal ? Qt.Vertical : Qt.Horizontal)
          }
      }
      

      Attachments

        Activity

          People

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            pradlol Alexander Kaminsky
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: