nvaccess / nvda

NVDA, the free and open source Screen Reader for Microsoft Windows
https://www.nvaccess.org/
Other
2.12k stars 637 forks source link

NVDA is unreliable to read new prompt in Windows Terminal automatically #14427

Open OSadovy opened 1 year ago

OSadovy commented 1 year ago

Steps to reproduce:

Actual behavior:

Observe that NVDA very often does not read newly coming text, so one has to use review commands to review it. Esp. this behavior is prevalent when new text consists of only one line, e.g. last command did not output anything.

Expected behavior:

NVDA should reliably read newly coming text.

Changing of a diffing algorithm does not seem to affect this behavior. Windows Narrator seems to reliably anounce newly coming text, so this is less likely to be the app UIA implementation itself.

NVDA logs, crash dumps and other attachments:

Developer info for navigator object:
name: 'Ubuntu-20.04'
role: Role.TERMINAL
processID: 10632
roleText: None
states: State.FOCUSABLE, State.FOCUSED
isFocusable: True
hasFocus: True
Python object: <NVDAObjects.Dynamic_WinTerminalUIAEditableTextWithAutoSelectDetectionUIA object at 0x04D7BA10>
Python class mro: (<class 'NVDAObjects.Dynamic_WinTerminalUIAEditableTextWithAutoSelectDetectionUIA'>, <class 'NVDAObjects.UIA.winConsoleUIA.WinTerminalUIA'>, <class 'NVDAObjects.behaviors.EnhancedTermTypedCharSupport'>, <class 'NVDAObjects.behaviors.Terminal'>, <class 'NVDAObjects.behaviors.LiveText'>, <class 'NVDAObjects.behaviors.EditableTextWithAutoSelectDetection'>, <class 'NVDAObjects.behaviors.EditableText'>, <class 'editableText.EditableText'>, <class 'NVDAObjects.UIA.UIA'>, <class 'NVDAObjects.window.Window'>, <class 'NVDAObjects.NVDAObject'>, <class 'documentBase.TextContainerObject'>, <class 'baseObject.ScriptableObject'>, <class 'baseObject.AutoPropertyObject'>, <class 'garbageHandler.TrackedObject'>, <class 'object'>)
description: 'lex@lex-dragonfly: ~/.local/lib'
location: RectLTWH(left=114, top=175, width=1730, height=894)
value: None
TextInfo: <class 'NVDAObjects.UIA.UIATextInfo'>
appModule: <'appModuleHandler' (appName 'windowsterminal', process ID 10632) at address 510ecf0>
appModule.productName: 'Microsoft.WindowsTerminal'
appModule.productVersion: '1.15.2875.0'
appModule.helperLocalBindingHandle: c_long(97286992)
windowHandle: 4456868
windowClassName: 'Windows.UI.Input.InputSite.WindowClass'
windowControlID: 0
windowStyle: 1342177280
extendedWindowStyle: 0
windowThreadID: 32832
windowText: ''
displayText: ''
UIAElement: <POINTER(IUIAutomationElement) ptr=0x5b4c058 at 4e7a710>
UIA automationID: 
UIA frameworkID: XAML
UIA runtimeID: (42, 4456868, 4, 4)
UIA providerDescription: [pid:10632,providerId:0x0 Main(parent link):Unidentified Provider (unmanaged:Windows.UI.Xaml.dll)]
UIA className: TermControl
UIA patterns available: LegacyIAccessiblePattern, TextPattern, ScrollItemPattern
diffing algorithm: <diffHandler.DiffMatchPatch object at 0x0418D590>

System configuration

NVDA installed/portable/running from source:

Installed

NVDA version:

2022.3.2

Windows version:

Windows 11 pro 22H2 (build 22621.819)

Name and version of other software in use when reproducing the issue:

Microsoft Windows Terminal 1.15.2875.0

Other information about your system:

Other questions

Does the issue still occur after restarting your computer?

Yes

Have you tried any other versions of NVDA? If so, please report their behaviors.

I think this was not happening on NVDA 2021.1 with windows 10. I am long user of the new windows terminal.

If NVDA add-ons are disabled, is your problem still occurring?

Does the issue still occur after you run the COM Registration Fixing Tool in NVDA's tools menu?

CyrilleB79 commented 1 year ago

Cc @codeofdusk

mzanm commented 1 year ago

Narrator uses uia notifications by terminal itself while NVDA uses textChange events. I believe it's a windows terminal issue as it doesn't always send a textChange event when the text changes for NVDA to diff.

codeofdusk commented 1 year ago

Duplicate of microsoft/terminal#10911.