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

Offscreen elements are not reachable with VoiceOver

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P2: Important
    • None
    • 6.8.1, 6.9.0
    • None
    • macOS

    Description

      We have encounter a problem while using VoiceOver on MacOS.

      As soon as an element is offscreen (while still visible: true), VoiceOver won't focus it.
      Side note: We are using the VO Key-Navigation Ctrl+Opt+Arrows as intended by Apple.

      This is a manyfold problem.
      Either the users have to constantly switch between scrolling and re-navigating to the content they want to read or they might even miss additional available content.
      Additionally devs like us have no opportunity to move the view for the users, since no new item is focused and we don't know the users intent to move to a new element.

      We identified the problem in

      qcocoaaccessibility.mm :: bool shouldBeIgnored(QAccessibleInterface *interface)
      

      where offscreen elements are ignored. This was introduced in ff5ae4a5785a12089910feda533e8230498ccfb7 and exists ever since.

      Removing the check solves the issue for us. So far we did not encounter glaring issues in doing so.

      Still we end up with some questions:

      Do you know why this was introduced in the first place?
      Do you know any negative side effects of removing the check?
      Are you willing to make such a change public or to make it configurable?

      Thank you and best regards,
      Timon

      To reproduce it you can construct a MWE like so. VoiceOver will just stop at the end and it wasn't even announced that the Flickable is scrollable. An impaired user would not know that he has to scroll for more content.
      Continuing to read offscreen elements would alleviate this issue.

      import QtQuick
      import QtQuick.Controls
      import QtQuick.Layouts
      
      Window {
      	width: 640
      	height: 480
      	visible: true
      	title: qsTr("Hello World")
      	Flickable {
      		anchors.fill: parent
      		contentWidth: layout.width; contentHeight: layout.height
      		ColumnLayout {
      			id: layout
      			width: 640
      			Repeater {
      				model: 200
      				Text {
      					id: txt
      					Accessible.focusable: true
      					Accessible.ignored: false
      					Accessible.name: text
      					Layout.maximumWidth: Math.ceil(implicitWidth)
      					text: (index + " ").repeat(10)
      					wrapMode: Text.Wrap
      
      					Rectangle {
      						anchors.fill: parent
      						color: "blue"
      						opacity: 0.1
      						visible: txt.focus
      					}
      				}
      			}
      		}
      		Rectangle {
      			anchors.fill: layout
      			color: "red"
      			opacity: 0.2
      		}
      	}
      }
      

      Attachments

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

        Activity

          People

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            timonsassor Timon Sassor
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There is 1 open Gerrit change