summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/wasm/qwasmaccessibility.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Create a menuItem element for accessibility when creating a MenuItem in a ↵Sharad Sahu2023-08-301-7/+19
| | | | | | | QML wasm application Change-Id: Iba862211b72372e1f48639c8b1edfa6336869fa5 Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
* Add description to the HTML tags using aria-descriptionShreya Pattani2023-08-111-6/+44
| | | | | | | | Description added to the html tags for accessibility in wasm through the aria-description property Change-Id: Ic1976d5c4c64ea45298f24b660807adeda6fdb64 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* Implement text update in wasm apps during accessibilityShreya Pattani2023-08-021-2/+5
| | | | | | | | | Implementation for QAccessibleEditableTextInterface is pending for texts in qml accessibility, adding accessibile role check for text to be updated when accessibility feature is on in wasm Change-Id: Ic24ebf6942e50a5952126e312afa633ed4fbe9ce Reviewed-by: Mikołaj Boc <Mikolaj.Boc@qt.io>
* wasm: build with -no-feature-accessibilityMorten Sørvig2023-05-021-1/+6
| | | | | | | | | Add #ifdefs around the accessibility implementation. Fixes: QTBUG-111509 Pick-to: 6.5 Change-Id: I9a600781b4bf9545f046efa75f962cc40fe196a6 Reviewed-by: Mikołaj Boc <Mikolaj.Boc@qt.io>
* Replace a duplicate symbolAmir Masoud Abdol2023-04-131-8/+2
| | | | | | | | | | | Removed the two identical functions and directly call the `static_cast` in their place. This is to resolve a build issue when doing unity build. Pick-to: 6.5 Task-number: QTBUG-109394 Change-Id: I174b601e06c4acdea45cc66495c09aafba6f48f6 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
* Wasm: Hide "Enable screen reader" button in QWasmWindowPiotr Wierciński2023-03-151-4/+1
| | | | | | | | | | | | | | | For each QWasmWindow, there is "Enable screeen reader" button added for accessibility. It's hidden visually by z-ordering behind main QWasmWindow div. Sometimes the content of QWasmWindow contains transparent elements and the underlying accessibility button gets visible. This commit introduces new CSS class which hides elements visually, but keeps it accessible for screen readers. Fixes: QTBUG-111896 Change-Id: I78ef5746da9e0d1584ee36dd0ca6ba476623a3de Reviewed-by: Mikołaj Boc <Mikolaj.Boc@qt.io> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: convert a11y coordinates to window coordinatesMorten Sørvig2023-02-031-1/+11
| | | | | | | | | | | The html accessibility elements are positioned relative to the window a11y container. Convert the global (screen) coordinates we get from QAccessibleIntreface::rect() to window coordinates. Pick-to: 6.5 Change-Id: Ifd4eb671def296b1eb418789b7ca85afa365e546 Reviewed-by: Mikołaj Boc <Mikolaj.Boc@qt.io>
* wasm: fix accessibility crash on null parentMorten Sørvig2023-02-031-10/+11
| | | | | | | | | | | The code was a assuming that an a11y interface always has a parent, which is not the case for the root interface. Also factor out to a getWindow() function, to prepare for re-use later on. Pick-to: 6.5 Change-Id: I52a841bf94c712deb9603e8b9c2c878820c5f117 Reviewed-by: Mikołaj Boc <Mikolaj.Boc@qt.io>
* wasm: Work on wasm accessibility elements and eventsShreya Pattani2022-12-271-9/+274
| | | | | | | | | | | Implement a11y support by adding html elements (Checkbox, Radio Button, TabView,Spinbox, ScrollBar, Slider, Event for Button) and events of the appropriate type and/or with the appropriate ARIA attribute behind the canvas. Pick-to: 6.5 Change-Id: I52902eae2bd4ac7a125815e1d2dd3077211fc118 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: Work on wasm accessibility elements and eventsSharad Sahu2022-12-271-4/+124
| | | | | | | | | | Implement a11y support by adding html elements (Toolbar, Menu, DialogBox) and events of the appropriate type and/or with the appropriate ARIA attribute behind the canvas. Pick-to: 6.5 Change-Id: If9c9fbff9a451b44e57de5d8834f4a78f33f41bc Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: add end-user accessibillty opt-inMorten Sørvig2022-12-271-17/+106
| | | | | | | | | | | | | | We want to make support for screen readers available incrementally to avoid destabilizing existing functionality. Accomplish this by initially adding a single "enable screen reader" button only. When pressed, this button will remove itself and populate the page with the actual accessibility elements. Pick-to: 6.5 Change-Id: I65036d249c408d4dc1fa75e8c807d9b7300e4722 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* Use the browser compositor for drawing windows on WASMMikolaj Boc2022-11-261-3/+4
| | | | | | | | | | | | | | | | Make the browser compositor draw the window non-client area (using css + html). Get rid of OpenGL usage in non-OpenGL windows and use canvas 2d context instead to blit the texture (QImage). Also, as part of the change, remove the deprecated canvas element support in QScreen. Fixes: QTBUG-107116 Fixes: QTBUG-107219 Change-Id: I65f0d91831c806315685ca681ac0e416673f5cd5 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io> Reviewed-by: Aleksandr Reviakin <aleksandr.reviakin@qt.io> Reviewed-by: David Skoland <david.skoland@qt.io>
* wasm: add accessibility logging categoryMorten Sørvig2022-11-081-8/+10
| | | | | | | | Use it for logging TODO items. Change-Id: If3218effcc7f044269defd5187ec080d4132d674 Reviewed-by: David Skoland <david.skoland@qt.io> Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
* wasm: include what you useMorten Sørvig2022-11-031-0/+2
| | | | | | | Change-Id: I0b35ca09314b8708de9ed811328ad1de8717f50d Reviewed-by: Mikołaj Boc <Mikolaj.Boc@qt.io> Reviewed-by: Lorn Potter <lorn.potter@gmail.com> Reviewed-by: Aleksandr Reviakin <aleksandr.reviakin@qt.io>
* wasm: begin work on accessibility backendMorten Sørvig2022-07-061-0/+250
Implement a11y support by adding html elements of the appropriate type and/or with the appropriate ARIA attribute behind the canvas. Also add a simple manual-test. Change-Id: I2898fb038c1d326135a1341cdee323bc964420bb Reviewed-by: Lorn Potter <lorn.potter@gmail.com>