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

Update InputScope mapping to be compatible with MS-IME as of Windows 11 22H2 #818

Closed
yukawa opened this issue Oct 14, 2023 · 0 comments
Closed

Comments

@yukawa
Copy link
Collaborator

yukawa commented Oct 14, 2023

Description

The current behavior upon setting InputScope in Mozc is based on Microsoft IME 2012.

However, MS-IME as of Windows 11 looks to be using a different mapping, which looks to be more consistent with "Don't use direct input mode" enabled as discussed in the following issue.

Interestingly MS-IME as of Windows looks to map IS_ALPHANUMERIC_HALFWIDTH to "IME Off" even when "Don't use direct input mode" is disabled though.

For better app compatibility, let's update Mozc's InputScope mapping to be compatible with the latest MS-IME.

While updating InputScope mapping is considered to be a subtask of #817, it's much easier than fixing other scenarios. Updating it is also sufficient to fix the following on-going app compatibility issue. So let's start from this easy part.

Expected behavior

Compatible with MS-IME as of Windows 11.

InputScope Expected Input Mode
IS_URL, IS_EMAIL_USERNAME, IS_EMAIL_SMTPEMAILADDRESS, IS_DIGITS, IS_NUMBER, IS_PASSWORD, IS_TELEPHONE_FULLTELEPHONENUMBER, IS_TELEPHONE_COUNTRYCODE, IS_TELEPHONE_AREACODE, IS_TELEPHONE_LOCALNUMBER, IS_TIME_FULLTIME, IS_TIME_HOUR, IS_TIME_MINORSEC, IS_ALPHANUMERIC_HALFWIDTH Direct Mode (IME Off)
IS_HIRAGANA Hiragana Mode (IME On)
IS_NUMBER_FULLWIDTH, IS_ALPHANUMERIC_FULLWIDTH Fullwidth Alphanumeric Mode (IME On)
IS_KATAKANA_HALFWIDTH Halfwidth Katakana Mode (IME On)
IS_KATAKANA_FULLWIDTH Fullwidth Katakana Mode (IME On)

Actual behavior

Compatible with Microsoft IME 2012. See our design doc.

InputScope Expected Input Mode
IS_URL, IS_EMAIL_USERNAME, IS_EMAIL_SMTPEMAILADDRESS, IS_DIGITS, IS_NUMBER, IS_PASSWORD, IS_TELEPHONE_FULLTELEPHONENUMBER, IS_TELEPHONE_COUNTRYCODE, IS_TELEPHONE_AREACODE, IS_TELEPHONE_LOCALNUMBER, IS_TIME_FULLTIME, IS_TIME_HOUR, IS_TIME_MINORSEC Direct Mode (IME Off)
IS_HIRAGANA Hiragana Mode (IME On)
IS_ALPHANUMERIC_HALFWIDTH Halfwidth Alphanumeric Mode (IME On)
IS_NUMBER_FULLWIDTH, IS_ALPHANUMERIC_FULLWIDTH Fullwidth Alphanumeric Mode (IME On)
IS_KATAKANA_HALFWIDTH Halfwidth Katakana Mode (IME On)
IS_KATAKANA_FULLWIDTH Fullwidth Katakana Mode (IME On)

Version or commit-id

6d80d75

Environment

  • OS: Windows 11 22H2
hiroyuki-komatsu added a commit that referenced this issue Oct 26, 2023
Typing quality
* Added  鵼(ぬえ) and 喃(のう) to the word dictionary.

Linux
* Fixed the crash issue of the candidate window UI (#820)

Windows
* Enabled the candidate window to respect the vertical writing mode (#362)
* Updated InputScope mapping to be compatible with MS-IME as of Windows 11 22H2 (#818, #826)
* Addressed the issue of no response on MS-Word (#819)
* Enabled the candidate window to consider per-monitor DPI settings (#832)

Build
* Enabled C++20 (#783)
* Switched to Qt 6.6.0 for Windows and macOS (#833)
* Reduced Qt6 binary size (#822)
* macOS: Fixed the non executable error of GUI tools with GYP
* Windows: Stopped specifying /BASE option (#834)
* Windows: Enabled Hardware Enforced Stack Protection (#835)
* Windows: Set default dependent load flags to Mozc executables for Windows (#836)
* Windows: Removed the dependency on CoCreateInpustance from mozc_tip dlls (#837)

PiperOrigin-RevId: 576830216
coooooooozy pushed a commit to coooooooozy/mozc that referenced this issue Nov 26, 2023
Mozc for Windows has been mapping IS_ALPHANUMERIC_HALFWIDTH InputScope
to "Halfwidth Alphanumeric Mode (IME On)" to be compatible with
Microsoft IME 2012.  However, recent versions of MS-IME map it to
"Direct Mode", probably to make it more consistent with their
default settings of "Don't use direct input mode" [1].

This discrepancy can result in unexpected user experiences when app
developers assume IS_ALPHANUMERIC_HALFWIDTH is a way to turn off IME
based on recent MS-IME's behavior [2].

Anyway, Mozc's design philosophy has been to emulate MS-IME's behavior
whenever possible.  Let's just update InputScope mapping to be
compatible with the latest version of MS-IME.

Closes google#818.

 [1]: google#817
 [2]: microsoft/terminal#14407

PiperOrigin-RevId: 573458610
coooooooozy pushed a commit to coooooooozy/mozc that referenced this issue Nov 26, 2023
Typing quality
* Added  鵼(ぬえ) and 喃(のう) to the word dictionary.

Linux
* Fixed the crash issue of the candidate window UI (google#820)

Windows
* Enabled the candidate window to respect the vertical writing mode (google#362)
* Updated InputScope mapping to be compatible with MS-IME as of Windows 11 22H2 (google#818, google#826)
* Addressed the issue of no response on MS-Word (google#819)
* Enabled the candidate window to consider per-monitor DPI settings (google#832)

Build
* Enabled C++20 (google#783)
* Switched to Qt 6.6.0 for Windows and macOS (google#833)
* Reduced Qt6 binary size (google#822)
* macOS: Fixed the non executable error of GUI tools with GYP
* Windows: Stopped specifying /BASE option (google#834)
* Windows: Enabled Hardware Enforced Stack Protection (google#835)
* Windows: Set default dependent load flags to Mozc executables for Windows (google#836)
* Windows: Removed the dependency on CoCreateInpustance from mozc_tip dlls (google#837)

PiperOrigin-RevId: 576830216
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

No branches or pull requests

1 participant