-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
6.9.1
-
None
-
-
4161ae0a7 (dev), cdfab6d1c (dev), 7ee235501 (6.10), fae28c88b (6.10), a5b2aaf49 (6.9), bf376368b (6.9), 9e9877e91 (tqtc/lts-6.8), 6b37ad473 (tqtc/lts-6.8), 6d0c380ac (dev), e909583e7 (6.10), bca8b133e (6.9), 357d3ca2e (tqtc/lts-6.8)
If a QML Item already is focused by the Screen Reader, changes to Accessible.name are not announced to the user.
On macOS this does work if the Accessible.role is not Accessible.StaticText. This seems to be by design which dates way back to the commit 5c608fb1202d93226a1cf95d96bf2d8008daf42. The reasoning is still valid as VoiceOver will still append ", text".
However, changes to Accessible.name should probably still be announced to the user.
The following MWE shows the issue at hand, changes to headingText are announced by the Screen Reader whereas changes to staticText are not.
ApplicationWindow {
height: 480
visible: true
width: 640
Column {
anchors.centerIn: parent
Text {
id: staticText
Accessible.name: text
Accessible.role: Accessible.StaticText
}
Text {
id: headingText
Accessible.name: text
Accessible.role: Accessible.Heading
}
}
Timer {
property int counter: 0
interval: 2000
repeat: true
running: true
triggeredOnStart: true
onTriggered: {
staticText.text = "StaticText %1".arg(counter);
headingText.text = "Heading %1".arg(counter);
counter += 1;
}
}
}