Bug 482753

Summary: PlaceholderMessage isn't accessible (eg: using a screen reader)
Product: [Frameworks and Libraries] frameworks-kirigami Reporter: Albert Vaca Cintora <albertvaka>
Component: generalAssignee: kdelibs bugs <kdelibs-bugs>
Status: RESOLVED FIXED    
Severity: normal CC: aleixpol, carl, me, nate, notmart, qydwhotmail
Priority: NOR    
Version: Master   
Target Milestone: Not decided   
Platform: Other   
OS: Other   
Latest Commit: Version Fixed In: 6.4
Sentry Crash Report:

Description Albert Vaca Cintora 2024-03-07 17:46:58 UTC
- `Kirigami.PlaceholderMessage` content isn't read by screen readers
- `Kirigami.Action` that don't have a text property don't use the `Accessible.name` property when using a screen reader.

STEPS TO REPRODUCE
Can be seen in the kdeconnect-app when using a screen reader.

Code for the app can be found here: https://github.com/KDE/kdeconnect-kde/blob/master/app/qml/
Comment 1 Nate Graham 2024-03-07 22:28:53 UTC
The issue with PlaceholderMessage is legit, but the issue with Action is a problem with client code. All Actions should have a text property even if it's not shown, for precisely this reason. And if they don't or can't, they should have Accessible.name set instead. All of those need to happen in client code, not in Kirigami.

I'll see about fixing up PlaceholderMessage.
Comment 2 Bug Janitor Service 2024-03-08 00:00:49 UTC
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/kirigami/-/merge_requests/1482
Comment 3 Bug Janitor Service 2024-03-08 00:00:51 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/libplasma/-/merge_requests/1073
Comment 4 Albert Vaca Cintora 2024-03-10 11:04:08 UTC
> And if they don't or can't, they should have Accessible.name set instead.
 Yeah, the bug is about Accessible.name not being honored.
Comment 5 Bug Janitor Service 2024-04-23 10:13:46 UTC
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/kirigami/-/merge_requests/1523
Comment 6 Aleix Pol 2024-04-23 11:46:31 UTC
Git commit a133a5ca6fe718ef033ce22b7a566a257966c6ae by Aleix Pol.
Committed on 23/04/2024 at 10:12.
Pushed by carlschwan into branch 'master'.

PageRow: Fix parent of Component-based pages

By using a non-graphical item we were leaving the page outside of the scene
and were getting a warning such as:
QML FindDevicesPage: Created graphical object was not placed in the graphics
scene.

This made the pages misregister in the accessibility infrastructure too,
making certain elements not be adequately registered in there.

M  +2    -1    src/controls/PageRow.qml

https://invent.kde.org/frameworks/kirigami/-/commit/a133a5ca6fe718ef033ce22b7a566a257966c6ae
Comment 7 Aleix Pol 2024-05-19 16:12:19 UTC
My change exposed it to systems but it still wasn't getting read by Orca. Needs to be announced explicitly.
Comment 8 Bug Janitor Service 2024-05-19 16:13:04 UTC
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/kirigami/-/merge_requests/1556
Comment 9 Aleix Pol 2024-06-03 21:43:24 UTC
Git commit 4fadd6c1e7425140abd52b9bda956dfc8adcb0b9 by Aleix Pol Gonzalez, on behalf of Aleix Pol.
Committed on 03/06/2024 at 21:33.
Pushed by apol into branch 'master'.

PlaceholderMessage: Announce the text and description to a11y

When a placeholder appears, announce its message. It's important so that
the placeholder doesn't go unnoticed to our a11y system.

Depends on:
https://codereview.qt-project.org/c/qt/qtdeclarative/+/562107

M  +15   -0    src/controls/PlaceholderMessage.qml

https://invent.kde.org/frameworks/kirigami/-/commit/4fadd6c1e7425140abd52b9bda956dfc8adcb0b9