Re: native equivalent of aria-live with NVDA

Florian Beijers

It is hard to really specify the exact level of abstraction because of my almost complete unfamiliarity with the way NVDA currently handles cases like this, as well as my unfamiliarity with the way UIA and friends handle cases like this. I'd say that your third case comes closest to what I am trying to do. Scenarios like:

- Given object X in the object navigation hierarchy, report any new text that is appended to the inner text of the object proactively.
- Given collection object Y in the object navigation hierarchy, look at any new incoming children and report their inner text, if any.
- Given non-focused object Z, monitor for changes in it's content or state and report based on a condition when either of these change.

A lot of apps do things you need to know about outside of the object you're currently focused on, but the way this is done is always different, which makes it hard to specifically ask a "how to do XYZ" question, as it were.
Your example looks promising for some of these scenarios though, I'll have a look at it, thanks.

Op za 1 mei 2021 om 21:57 schreef James Scholes <james@...>:

As I often find myself saying on this list, it will help greatly if you described what you're trying to do.  The context really matters here.  For example:

1. If you're trying to develop or modify a Windows app to fire screen reader announcements, UIA does support a very similar concept to an ARIA live region.  The technologies used to implement that app will determine how easily you can gain access to the functionality, e.g. in a .NET WinForms app it's as easy as adding a control to a form and setting its text.  In a wxPython app, not so much.
2. If you just want your add-on to say something, import ui and use ui.message.
3. If you're developing an add-on for an application with an updating stream of text, like a console-style interaction, and you want NVDA to automatically speak text as it comes in, there are ways to do that which I've never quite managed to get my head around.  Try NVDAObjects.window.DisplayModelLiveText as a starting point.


James Scholes

On 01/05/2021 at 2:20 pm, Florian Beijers wrote:
> Hi,
> I am a web developer first and foremost, and don't have a huge amount
> of experience interacting with UIA and friends directly, so this is
> really me looking for an analog to the concept I know.
> Is there a pattern for the web concept of aria-live, where a
> particular element on screen immediately echoes new text, but only the
> new text, to NVDA as it comes in?
> Think new messages in a chat window, new output for a terminal
> program, that kind of thing.
> If so, is there an example in some NVDA addon, guide, post or email
> thread  where I can see how this is done?
> Thanks,
> Florian

Join to automatically receive all group messages.