Skip to content

Windows 11 IME: announce visible candidates when the IME interface opens#16541

Merged
seanbudd merged 5 commits into
nvaccess:masterfrom
josephsl:i14023enhancedWindows11IMEInterface
May 14, 2024
Merged

Windows 11 IME: announce visible candidates when the IME interface opens#16541
seanbudd merged 5 commits into
nvaccess:masterfrom
josephsl:i14023enhancedWindows11IMEInterface

Conversation

@josephsl

Copy link
Copy Markdown
Contributor

Link to issue number:

Closes #14023

Summary of the issue:

NVDA does not announce visible IME candidates in Windows 11.

Description of user facing changes

NVDA wil once again announce visible IME candidates when Windows 11 modern IME interface opens.

Description of development approach

Modern keyboard app module changes:

  • IME candidate UI lass: handle focus entered evdent, announcing visible candidates when IME interface opens.
  • IME candidate item: move Windows 11/Automation Id check to the end of the element selected event handler just before self.reportFocus() call so visible candidates can be anounced when switching between IME pages.

Testing strategy:

Manual testing (requires presence of IME interface language(s) such as Chinese, Japanese, and Korean):

  1. In Windows 11, switch input language to a language offering IME interface.
  2. Switch to native keyboard input mode.
  3. Type something in the native language.
  4. Press a key to open IME interface (in Korean, this is right Control key)
  5. Optional: move through the IME candidates, switching between multiple pages.

Known issues with pull request:

Visible IME candidates could be announced twice when the IME interface first opens - this is because element selected event is fired prior to focus entered/gain focus event. Thankfully, the app module holds visible candidates for the first page, so IME candidates list will not be repeated if the candidates list are the same. Also, if the visible IME candidates are less than 9, NVDA will just announce candidate number instead of entries (perhaps this could be a separate issue).

Code Review Checklist:

  • Documentation:
    • Change log entry
    • User Documentation
    • Developer / Technical Documentation
    • Context sensitive help for GUI changes
  • Testing:
    • Unit tests
    • System (end to end) tests
    • Manual testing
  • UX of all users considered:
    • Speech
    • Braille
    • Low Vision
    • Different web browsers
    • Localization in other languages / culture than English
  • API is compatible with existing add-ons.
  • Security precautions taken.

josephsl added 4 commits May 13, 2024 09:26
…Automation Id check to end of the event handler. Re nvaccess#14023.

When modern IME interface opens, NVDA does not report visible IME candidates, caused by element selected event returning early if running on Windows 11, checking for Automation Id, and to avoid gain focus event/repetitions. To allow reporting of IME candidates, move Windows 11 and Automatoin Id checks to just before reportFocus call so visible IME candidates can be announced. This, together with the next commit (focus entered event), allows NVDA to announce IME candidates in Windows 11.
…candidates. Re nvaccess#14023.

Prior to IME candidate receiving gain focus event, focus entered event is received by IME interface. This gives it a chance to ask IME candidate to perform its element selected event, hopefully announcing visible candidates. However, candiate item's element selected event handler's navigator objec check occurs, and because navigator object is indeed the focused candidate item, visible candidates are not announced. Therefore, announce visible candidates (if told to do so) from focus entered event.
@josephsl josephsl requested a review from a team as a code owner May 13, 2024 15:45
@josephsl josephsl requested a review from gerald-hartig May 13, 2024 15:45
@josephsl josephsl changed the title Windows 11 IME: announce visile candidates when the IME interface opens Windows 11 IME: announce visible candidates when the IME interface opens May 13, 2024
@AppVeyorBot

Copy link
Copy Markdown

See test results for failed build of commit c20476fd60

@seanbudd seanbudd added the conceptApproved Similar 'triaged' for issues, PR accepted in theory, implementation needs review. label May 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

conceptApproved Similar 'triaged' for issues, PR accepted in theory, implementation needs review.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Windows 11 modern keyboard: support modern input method editor interface

3 participants