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

TextArea and TextField don't use IBeamCursor when readOnly and selectByMouse are both true

    XMLWordPrintable

    Details

    • Commits:
      1d3e219e56 (qt/qtdeclarative/dev) 756add49a6 (qt/qtdeclarative/6.2) 756add49a6 (qt/tqtc-qtdeclarative/6.2) 1d3e219e56 (qt/tqtc-qtdeclarative/dev) 756add49a6 (qt/qtdeclarative/6.2.4) 8cf3891b76 (qt/qtdeclarative/6.3) 8cf3891b76 (qt/tqtc-qtdeclarative/6.3)

      Description

      IBeamCursor should be used when a pointing device can be used to select text or position a text cursor, just like on the web. Instead, TextArea and TextField use ArrowCursor when readOnly is true, even when selectByMouse is also true.

      import QtQuick 2.15
      import QtQuick.Controls 2.15
      
      ApplicationWindow {
          width: 400
          height: 400
          visible: true
      
          Flow {
              anchors.fill: parent
      
              Repeater {
                  model: [
                      { readOnly: false, selectByMouse: false },
                      { readOnly: false, selectByMouse: true },
                      { readOnly: true, selectByMouse: false },
                      { readOnly: true, selectByMouse: true },
                  ]
                  delegate: TextArea {
                      text: "readOnly: " + readOnly + " selectByMouse: " + selectByMouse
                      readOnly: modelData.readOnly
                      selectByMouse: modelData.selectByMouse
                  }
              }
          }
      }
      

        Attachments

          Issue Links

          For Gerrit Dashboard: QTBUG-99604
          # Subject Branch Project Status CR V

            Activity

              People

              Assignee:
              qt.team.quick.subscriptions Qt Quick and Widgets Team
              Reporter:
              ndavis Noah Davis
              Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes