ui_find
Locate desktop widgets by visible text or role, then act on them via the accessibility tree. Find first, act immediately, as paths stay valid only while the interface remains unchanged.
Instructions
Find widgets by visible text. THE way to locate something to act on: pressing a real widget through AT-SPI cannot miss and does not care where the window moved to. Paths returned here are valid only while the tree is unchanged -- find, then act.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| app | No | Restrict to one application (much faster) | |
| role | No | Require an exact AT-SPI role, e.g. push_button | |
| text | No | Substring to look for in widget names. Optional if role or actionable_only is given -- which is how you list the icon-only buttons that have no name to search. | |
| depth | No | GTK4 nests deeply -- the default is 30 because a text view can sit at depth 23 | |
| actionable_only | No | Only widgets that expose an action |