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

REG 5.10->5.10.1: TextArea background not anchoring correctly

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P1: Critical P1: Critical
    • None
    • 5.10.1, 5.11.0 Beta 2
    • Quick: Controls 2
    • None
    • Windows MSVC2015 64bit

      QtQuick Controls 2 TextArea background doesn't anchor into TextArea but instead into ScrollView and scrolls away with its content. Adding id property for background item fixes this so likely related to https://bugreports.qt.io/browse/QTBUG-50992 but still happens with latest qt5 5.11 branch (7c19a3f83b)

      Related code snippet:

      ...
          ScrollView {
              id: sourceScrollView
              anchors.fill: parent
              anchors.margins: 10
              TextArea {
                  id: sourceTextArea
                  text: "1\n2\n3\n1\n2\n3\n1\n2\n3\n1\n2\n3\n1\n2\n3\n1\n2\n3\n"
                  background: Rectangle {
                      // Note: id required due to QTBUG-67446
                      //id: sourceScrollViewBackground
                      width: parent.width
                      border.color: "#202020"
                      color: "#a0a0a0"
                  }
              }
          }
      ...

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

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            kagro Kaj Grönholm
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes