diff options
| author | Michael Weghorn <[email protected]> | 2025-10-01 14:59:07 +0200 |
|---|---|---|
| committer | Michael Weghorn <[email protected]> | 2025-10-28 14:08:59 +0200 |
| commit | b53656bfa70461a643ff564ff33eb2c049316e15 (patch) | |
| tree | b3af62a1c6adf7608947950c069e946c1854e609 /src/gui/util/qundostack.cpp | |
| parent | fa39bf742c729f91219c52218410cfd64b020fdd (diff) | |
a11y: Introduce accessible attribute for orientation
Introduce QAccessible::Attribute::Orientation to allow
reporting an explicit orientation for an object.
Drop the comments about horizontal and vertical
for QAccessible::State. This no longer needs any
consideration on whether or not to introduce such states,
as it is implemented as an attribute now (that can indicate
either horizontal or vertical orientation, instead of having
two separate states).
Allowing to explicitly set an orientation is for
example helpful for scroll bars, so assistive technology
users know what orientation those have, and what keyboard
shortcuts apply (e.g. up/down keys to change the scrollbar
position for a vertical scroll bar, left/right keys to
change the position of a horizontal one).
Corresponding states/attributes/properties exist in multiple
platform a11y APIs:
* Linux/AT-SPI2: states ATSPI_STATE_HORIZONTAL [1] and
ATSPI_STATE_VERTICAL [2]
* Windows/UIA: UIA_OrientationPropertyId [3]
* macOS: NSAccessibilityOrientation [4]
* web/ARIA: "aria-orientation" property [5]
Initially, handle the new attribute in the AT-SPI2 adapter
for Linux.
Handling for more platform a11y bridges and using the new
states to report the QAbstractSlider orientation will be
implemented in separate upcoming commits.
[1] https://gnome.pages.gitlab.gnome.org/at-spi2-core/libatspi/enum.StateType.html#horizontal
[2] https://gnome.pages.gitlab.gnome.org/at-spi2-core/libatspi/enum.StateType.html#vertical
[3] https://learn.microsoft.com/en-us/windows/win32/winauto/uiauto-automation-element-propids
[4] https://developer.apple.com/documentation/appkit/nsaccessibilityorientation
[5] https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Reference/Attributes/aria-orientation
[ChangeLog][QtGui][QAccessible::Attribute] Added new
Orientation enum value that can be used to specify the
orientation of an accessible object.
Task-number: QTBUG-140769
Change-Id: I87ac29447622189561fa7f25947cfd7f6b028056
Reviewed-by: Volker Hilsheimer <[email protected]>
Reviewed-by: MohammadHossein Qanbari <[email protected]>
Diffstat (limited to 'src/gui/util/qundostack.cpp')
0 files changed, 0 insertions, 0 deletions
