Conversation
The accessibility backend had only Value/Invoke/Toggle/Grid-read, so treeviews, listboxes/combos, sliders and off-screen rows had no native pattern path. Add ExpandCollapse / SelectionItem / RangeValue / ScrollItem actions on top of the existing backend ABC, dispatched through the injectable get_backend() seam (headless-testable via a fake backend; real UIA calls in the Windows backend).
The test's _FakeBackend overrode pattern methods with **kw instead of the explicit name/role/app_name/automation_id signature, which Codacy/Pylint flags as arguments-differ. Use the same signatures as AccessibilityBackend.
…erns-batch Add control_patterns: extended UIA patterns (Expand/Select/Range/Scroll)
ValuePattern returns empty on multiline edits, RichEdit and document controls, so control_get_value can't read exactly the controls whose text matters most. Read through UIA TextPattern instead: full document, current selection, and visible-only text. Dispatched via the injectable accessibility backend seam so the core is headless-testable; real UIA calls live in the Windows backend.
Add ax_text: native TextPattern reads (document / selection / visible)
dump_accessibility_tree emits the platform's raw role (on Windows the bare UIA ControlType id, e.g. ControlType_50000) and a serialised dump carries no stable per-node identity. Add the pure post-processing it lacks: a ControlType-id to friendly-name table, whole-tree role humanization, a stable positional path per node (a pure stand-in for RuntimeId), and path resolution. AC_walk_tree is the readable counterpart to AC_a11y_dump.
…-batch Add ax_tree_walk: readable roles + addressable node paths for a11y dumps
Nothing reasoned about keyboard navigation — only mouse coordinates and element values. Add the keyboard layer: tab_order returns focusable elements in the order Tab visits them (reading order), audit_focus_order is a WCAG 2.4.x report flagging problems like zero-area focusable elements, and focus_control sets keyboard focus via UIA SetFocus. The pure parts reuse element_parse.reading_order and ax_tree_walk.humanize_role; focus_control dispatches the injectable backend seam.
…batch Add focus_order: keyboard tab sequence, WCAG focus-order audit, set-focus
Up to standards ✅🟢 Issues
|
| Metric | Results |
|---|---|
| Complexity | 168 |
| Duplication | 0 |
NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Release: native-UI control depth (v181–v184)
Bundles the completed native-UI HIGH lane — four features deepening UI Automation control coverage, each merged to
devCI-green (Codacy 0 / SonarCloud OK / all matrices + Docker).control_patterns(v181, Add control_patterns: extended UIA patterns (Expand/Select/Range/Scroll) #397) — Expand/Collapse, SelectionItem, RangeValue, ScrollItem patterns on the accessibility backend ABC.ax_text(v182, Add ax_text: native TextPattern reads (document / selection / visible) #398) — UIA TextPattern reads (get_control_text/get_selected_text/get_visible_text); fixes ValuePattern returning empty on multiline/document controls.ax_tree_walk(v183, Add ax_tree_walk: readable roles + addressable node paths for a11y dumps #399) — readable roles (ControlType id → name) + stable positional node paths overdump_accessibility_tree.focus_order(v184, Add focus_order: keyboard tab sequence, WCAG focus-order audit, set-focus #400) — keyboard Tab order, WCAG 2.4.x focus-order audit, andfocus_control(UIA SetFocus).All four share the injectable
accessibility.backends.get_backend()seam (headless-testable via fake backends; real UIA calls in the Windows backend) and stay Qt-free. The pure post-processors reuse existing helpers (element_parse.reading_order,ax_tree_walk.humanize_role) rather than duplicating logic. EN/Zh docs (v181–v184) + WHATS_NEW entries included.