-
-
Notifications
You must be signed in to change notification settings - Fork 650
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Text on the braille display doesn't update after using Undo in Word #3276
Comments
Comment 1 by jteh on 2013-06-20 01:55 |
Comment 2 by mdcurran (in reply to comment 1) on 2013-06-20 04:01
I'm really not sure off the top of my head. We certainly don't use any MS Word COM events right now. Also, based on experiences with PowerPoint and Protected mode etc, I'm thinking that scripts, as long as they do the trick are quicker to code and have more chance of working in high-security situations such as protected mode. |
Comment 3 by falinn.onda (in reply to comment 2) on 2013-06-21 05:18 I would like to add that undo is not the only case that creates synchronization issues, while braille is thathered to focus. Examples include:
For some reason when braille tathered to review it is synchronized a bit differently. In this case CTRL+DELETE updates braille display. If If you think that that there is a way for word to notify NVDA upon change, in general, i think it might solve many braille synchronization issues. Either way of fixing synchronization on the above mentioned cases will be welcomed. |
Could Braille experts please test and report whether these Braille synchronization issues (particularly with MS Word's Undo and Redo, Ctrl+Backspace and Ctrl+Delete) still occur? |
@falinn.onda is this issue still reproducible? |
I can still reproduce this with Word 2016, non-UIA. It isn't specific to a particular braille display. |
@dkager how is this now with NVDA 2023.1 RC1 or NVDA 2022.4? |
I tried locally to add It worked almost. If there is for example: "12345", and then ctrl-z is pressed 5 times, there is not necessarily blank display. If pressing and holding ctrl-z it seems to work or if pressing ctrl-z with long delay between presses, it seems to work also. But if something between these, it may not work. @LeonarddeR what do you think about this? Is my approach wrong? |
@burmancomp is this with or without UIA enabled in Word? |
Do you mean this setting: "Use UI Automation to access Microsoft Word document controls"? It is currently " Default (Where suitable)". |
In blank document typing q then ctrl-z. Quite often q remains in braille line. If there are more characters like qwerty, others y, t ... seems to be removed correctly. It seems that |
BB |
It may work better with UIA set to always, and when NVDAObjects\UIA\wordDocument.py also includes event_caret. I have understood that UIA does not work properly in ms word before Windows 11. I have not Windows 11 installed. I'm considering if it would be worth of opening draft pull request. I suppose that braille.handler.handleUpdate should be enough in most cases but when document contains only 1 character and then ctrl-z is pressed to undo this does not work always. As if caret event would not be fired every time, but why it is happening (if this is the case), I do not know. |
Well if a pr doesn't fix 100% of the instances of the issue, it might be
better to get more to the bottom of it.
I might be able to do some tests later this week. I think we need to
search more in the lines of event_textChange
|
I added event_textChange, event_textInsert and event_textRemove functions to WordDocument class which just write a log line. It seems that any of these events were never fired because there was no log line they should have written. I should have time to test so let me know what you think I could try. |
It seems that this is larger issue because display is not necessarily updated when using ctrl+x. |
I have also noticed that when in blank document, repeating following steps may cause situation where entered character is not updated to braille display:
Log lines are attached. Version is current main branch source. |
…pace or control+backspace is pressed and UIA not used in ms word (#15491) fixes #3276 Summary of the issue: After paste, cut, redo, undo, backspace or control+backspace braille line was not necessarily updated when using object model. Description of user facing changes Braille line and review position should always be updated when using object model ("Use UI Automation to access Microsoft Word document controls" is not set to always in NVDA's advanced settings category), and paste (control+v), cut (control+x), redo (control+y) or undo (control+z / alt+backspace) is pressed. Braille should be also updated when using object model and backspace or control+backspace is pressed and held down. Braille and review position are also updated when using UIA, and braille is tethered to review and review follows caret. Description of development approach To get control+v, control+x, control+y, control+z and alt+backspace to work, added helper script script_updateBrailleAndReviewPosition to NVDAObjects.IAccessible\winword.WordDocument, and assigned corresponding keyboard shortcuts to it. Minor modification of event_caret so that braille is always updated when caret event is executed from script_updateBrailleAndReviewPosition. To update braille always when backspace or control+backspace are pressed and held down, overridden _backspaceScriptHelper function. In addition, to get braille updated when tethered to review and when review follows caret, modified event_textChange in UIA\wordDocument.py.
Reported by falinn.onda on 2013-06-10 17:16
Hi,
Assuming you do the following:
Expected behavior: braille displays "123" as the current document content after undo.
Actual behavior: Braille displays "1234"
I am using Focus 40 blue via Bluetooth.
The text was updated successfully, but these errors were encountered: