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

Popup's contentItem isn't mirrored if no Window exists

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Reported
    • Priority: P3: Somewhat important
    • Resolution: Unresolved
    • Affects Version/s: 5.10
    • Fix Version/s: None
    • Component/s: Quick: Controls 2
    • Labels:
      None

      Description

      If Popup can't find an Window, it doesn't apply RTL mirroring.

      This can be a problem with applications like widgets in Plasma having a ComboBox.

      import QtQuick 2.7
      import QtQuick.Layouts 1.3
      import QtQuick.Controls 2.3
      import QtQuick.Window 2.2
      
      Item { //with Window the RowLayout in myPopup order is reversed (mirroring is applied)
          LayoutMirroring.enabled: true
          LayoutMirroring.childrenInherit: true
      
          width: 350
          height: 150
      
          RowLayout {
              anchors.fill: parent
              Button {text: "1"}
              Button {
                  text: "2 clickable"
                  onClicked: {
                      myPopup.open()
                      console.log(myPopup.contentItem.LayoutMirroring.enabled)
                  }
              }
          }
      
          Popup {
              id: myPopup
              Component.onCompleted: {
                  console.log("completed")
                  console.log(contentItem.LayoutMirroring.enabled)
              }
              RowLayout {
                  anchors.fill: parent
                  Button {text: "1"}
                  Button {text: "2"}
              }
          }
      }
      

        Attachments

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

          Activity

            People

            • Assignee:
              qt.team.quick.subscriptions Qt Quick and Widgets Team
              Reporter:
              safa alfulaij Safa Alfulaij
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:

                Gerrit Reviews

                There are no open Gerrit changes