CoreWindow::CharacterReceived event didn't work for Japanese symbols

Camran Boyle 6 Reputation points
2021-08-16T16:50:09.033+00:00

I'm supporting UWP application and it uses pure DirectX, no XAML at all. Customer reported that he can't work with Japanese symbols. So I did some checking and found that for some reason CoreWindow::CharacterReceived method returns Latin symbols even if Japanese language selected in the system. This method works perfectly for Cyrillic symbols and even for Japanese if user uses IME Pad(soft keyboard). But not for hardware keyboard. Also other apps, like Notepad receives Japanese symbols with no problem

Universal Windows Platform (UWP)
C++
C++
A high-level, general-purpose programming language, created as an extension of the C programming language, that has object-oriented, generic, and functional features in addition to facilities for low-level memory manipulation.
3,559 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Nico Zhu (Shanghai Wicresoft Co,.Ltd.) 12,856 Reputation points
    2021-08-17T03:16:31.02+00:00

    Hello, Welcome to Micorosoft Q&A,

    CoreWindow::CharacterReceived event didn't work for Japanese symbols

    I have to say it's by-design, please refer to CharacterReceived documentation.

    Apps do not receive this event when an Input Method Editor (IME) is enabled. The Input Method Editor (IME) handles all keyboard input and sets Handled to true.

    if you want trigger this event, you need to disable ime before typing.


    If the response is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.