Finish up edit field accessibility.

This commit is contained in:
ak47 committed 2026-10-10 00:18:22 -04:00
1 parent 6f6d4040c4
commit c5657ee5d4
9 files changed
+361 -39

No files matched your search

+28
View File
@@ -87,6 +87,27 @@ repeated selections, and restores standard-control focus reporting when menus
close. The hook applies to the helper's Wine desktop and prefix and is removed
on normal shutdown. It is disabled by `--no-dialog-reader`.
The same DLL subclasses standard `Edit` controls, including Wine Notepad's
document area. It reports the current line on focus and menu return, characters
and words on horizontal navigation, lines on vertical/page/document-boundary
navigation, changed selections, and Backspace/Delete/Cut feedback. Password
contents are excluded, and read-only edits do not report unsuccessful deletions.
Undo refreshes the text snapshot used by subsequent navigation. It can attach to
an already-focused editor and resume after the helper restarts.
Editor actions use `PresentAccessibleEvent` with event type `text`; actual focus
uses `focus`. Cthulhu-Go must include the corresponding editor-event support so
rapid actions and repeated characters bypass focus coalescing. UTF-16 selection
offsets and the action kind travel in the otherwise non-spoken `states` field
for debug diagnostics. Older readers that only accept focus/value/selection
events still receive focus and menus, but need updating for editor actions.
This is editing feedback, not a full text-review provider: Say All, review-cursor
commands and braille routing into Wine text are not implemented. Typing echo
remains the reader's responsibility. RichEdit and 32-bit editor hooks are not
covered. Reports are limited to 1023 UTF-16 units; documents over one million
units use line feedback without full selection/deletion snapshots.
Keep all three installed files together. The native hook currently targets
64-bit applications; 32-bit menu coverage and custom menus that do not send
`WM_MENUSELECT` are not established.
@@ -98,6 +119,8 @@ available (`python-gobject` on Arch Linux):
```sh
python3 tests/menu_integration.py --build-dir build
python3 tests/menu_integration.py --build-dir build --fixture edit
python3 tests/menu_integration.py --build-dir build --fixture notepad
```
The test opens a short-lived native menu window in a temporary Wine prefix,
@@ -106,6 +129,11 @@ context menus, shortcuts, item states, and duplicate suppression. It does not
send speech or braille to the running reader. Live listening with Cthulhu is a
separate acceptance check.
See [the test guide](tests/README.md) for helper lifecycle checks and the live
Notepad speech/braille procedure. After updating the DLL, close and reopen the
Wine application: existing control subclasses keep their DLL loaded until the
application exits.
## License
The helper source is available under the terms of LGPL-2.1-or-later. See