Skip to content

[IME Compatibility] Text is duplicated when committing with Shift key in WeChat Input (微信输入法) #19507

Description

@laiwang233

Describe the bug

When using the WeChat Input IME (微信输入法) in its Chinese mode, committing text to a TextBox by pressing the Shift key causes the text to be inserted twice.

For example, typing "hello" and then pressing Shift results in "hellohello" appearing in the TextBox.

This issue is specific to the WeChat Input IME. The bug does not occur when using the standard Microsoft Pinyin IME, which behaves correctly under the same conditions.

To Reproduce

  1. Set the system IME to WeChat Input.
  2. Switch the IME to its Chinese mode.
  3. Focus a TextBox in an Avalonia 11.3.4 application.
  4. Type an English word, e.g., "test".
  5. Press the Shift key.
  6. Expected Result: The TextBox contains "test".
  7. Actual Result: The TextBox contains "testtest".

Expected behavior

When typing an English string (e.g., "hello") in the WeChat Input IME's Chinese mode, pressing the Shift key should commit the text to the TextBox only once.

The expected result should be "hello", not "hellohello".

Avalonia version

Avalonia Version: 11.3.3

OS

Windows

Additional context

JTest.zip
I have attached a minimal project that reproduces the bug. The project contains a single window with a standard TextBox.

Image

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions