check_focus_order
Press Tab or a key until focus cycles to map keyboard focus order, list every stop, unreached controls, and whether focus loops, gets stuck, or is lost.
Instructions
Check the keyboard focus order in one call: press Tab, or key, until the focus comes back round, and list where it went, a tree line each, after a "began in" line. Then the controls the key never reached, and how it ended: round again (fine), stuck (a trap, or a text view nothing leaves), not round after most presses, lost (no node has the focus), stopped (a text view closed as it was left), or nothing focused to begin with (click the window with click_element first). With visible, "focus not shown on N" counts stops that don't show it. A text view that takes Tab is left as a person would, with ctrl+Tab, shift+Tab, Escape or F6. The focus stays where it ended. To press a few keys yourself, use press_keys.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | No | The chord to press (Tab) | |
| most | No | Presses at most (50) | |
| ignore | No | Regexes for unreached controls to leave out | |
| window | No | A window's title, exactly or a regex matched in full, or app=RE for its app id | |
| session | Yes | Its name, from start_session | |
| visible | No | Also check each place it lands shows it has the focus |