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

Cannot change Windows 10/11 touch keyboard to Traditional Chinese phonetic layout #358

Open
youjhihchao opened this issue Aug 14, 2024 · 0 comments

Comments

@youjhihchao
Copy link

youjhihchao commented Aug 14, 2024

I am the author of a Traditional Chinese Input Method (IME).

My IME functioned well in Windows 10 versions prior to 1703. However, since the release of Windows 10 Version 1709, the screen keyboard only displays the English layout instead of the Chinese Phonetic (Bopomofo) layout.

Steps to reproduce the issue:

  • Download the SampleIME project from this link: SampleIME, and open it in Visual Studio Community 2015.
  • In Define.h, change the following line:
    #define TEXTSERVICE_LANGID MAKELANGID(LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED)
    to
    #define TEXTSERVICE_LANGID MAKELANGID(LANG_CHINESE, SUBLANG_CHINESE_TRADITIONAL)
  • In SampleIME.cpp, modify this line:
    *pwPreferredLayoutId = TKBL_OPT_SIMPLIFIED_CHINESE_PINYIN;
    to
    *pwPreferredLayoutId = TKBL_OPT_TRADITIONAL_CHINESE_PHONETIC;
  • Build the project.
  • Register the COM object by running: regsvr32.exe Debug/SampleIME.dll
  • Run Notepad.exe, switch the keyboard to "Sample IME", and activate the touch/screen keyboard.

The screen keyboard will only display the English layout instead of the Chinese Phonetic layout.

After tracing and debugging, it appears that the system does not invoke ITfFunctionProvider::GetFunction to query IID_ITfFnGetPreferredTouchKeyboardLayout, which would otherwise allow the GetLayout method to change the touch keyboard layout.

I would greatly appreciate any insights or solutions you could provide for this issue.

Thank you for your assistance.

EnglishKeyboard
ZhuyinKeyboard2

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