Skip to content
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

Add textInfos unit mappings for UIA document, page and format field, make FORMATFIELD and CONTROLFIELD units global #10396

Merged
merged 1 commit into from
Oct 21, 2019

Conversation

LeonarddeR
Copy link
Collaborator

Link to issue number:

None

Summary of the issue:

The _UIAHandler.NVDAUnitsToUIAUnits mapping is incomplete, not containing document and page.

Description of how this pull request fixes the issue:

I added these units. I also discovered that we have TextUNitFormat, which is equivalent to NVDA format fields. Therefore, I moved the UNIT_CONTROLFIELD and UNIT_FORMATFIELD units from VirtualBufferTextINfo to the textInfos package. This should make the code more consistent and also fixes a theoretical bug where BrowseModeDocumentTreeInterceptor.event_caretMovementFailed tried to use UNIT_CONTROLFIELD on a TextInfo that didn't have this constant.

Testing performed:

Tested that in Word with UIA enabled, I can expand to page, story and format field.

Known issues with pull request:

None

Change log entry:

  • Changes for developers
    • The UNIT_CONTROLFIELD and UNIT_FORMATFIELD constants have been moved from virtualBuffers.VirtualBufferTextInfo to the textInfos package.
    • UIA TextInfo objects can now be moved/expanded by the page, story and formatField text units.

…make FORMATFIELD and CONTROLFIELD units global
@LeonarddeR LeonarddeR added this to the 2019.3 milestone Oct 18, 2019
@LeonarddeR
Copy link
Collaborator Author

Added this to the 2019.3 milestone because the pr is pretty small and includes a backwards incompatible change.

@michaelDCurran michaelDCurran merged commit 934bf77 into nvaccess:master Oct 21, 2019
michaelDCurran added a commit that referenced this pull request Oct 21, 2019
@LeonarddeR LeonarddeR deleted the UIATextUnits branch November 21, 2019 09:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants