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

Chinese input problem #19

Open
DrMerfy opened this issue Feb 22, 2021 · 12 comments
Open

Chinese input problem #19

DrMerfy opened this issue Feb 22, 2021 · 12 comments

Comments

@DrMerfy
Copy link
Owner

DrMerfy commented Feb 22, 2021

Issue Type: Bug

Overtype mode is off
Type some Chinese characters (using Microsoft ChangJie for example)
The character before the caret will be overtyped / eaten
Extension version: 0.2.0
VS Code version: Code 1.52.0 (940b5f4bb5fa47866a54529ed759d95d09ee80be, 2020-12-10T22:45:11.850Z)
OS version: Windows_NT x64 10.0.18363

Based on: AdamMaras#24

Original issuers/commenters:
@avin-shum @NavyD @yoursunny

@tetsumetal1964
Copy link

Same with Japanese Input.
It was hard to find out the issue is related to overtype and discussed here.
I was stopping use of vscode with Japanese text for a few week.
Anyway, thank you for your contribution!

Extension version: 0.2.0
VS Code version: Code 1.56.2

@yowynn
Copy link

yowynn commented Jul 26, 2021

SAD :(

@DrMerfy
Copy link
Owner Author

DrMerfy commented Jul 26, 2021

Tried to play around a bit with overtype and Chinese letters, the behaviour that I'm getting is that:

Screen.Recording.2021-07-26.at.11.46.21.mov

Could you share a video with the issue to better understand which is the incorrect behaviour?

(on VSCode version: 1.58.0)

@avin-shum
Copy link

avin-shum commented Aug 11, 2021

@DrMerfy Please find my screen capture below:

Expected behaviour:
In Overtype mode, the text "一二三四五六七八九十" should becomes "一二朋友五六七八九十".
Note: "朋" is formed by codes "月月", and "友" is formed by codes "大水".

Without Overtype Extension:

  • "朋友" is inserted before "三四", which is expected.
    without-ovetype-extension.gif

With Overtype Extension (Overtype mode):

  • When keying "月月" for "朋", the first code replaces the character before the cursor (二), then the formed character "朋" replaces the position of the cursor (三).
  • Similarly, for "友", the first code replaces the character before the cursor (朋), then the formed character "朋" replaces the position of the cursor (四).
    overtype-mode-with-overtype-extension.gif

With Overtype Extension (Insert mode)

  • When keying "月月" for "朋", the first code replaces the character before the cursor (二), then the formed character "朋" inserted at the position of the cursor.
  • Similarly, for "友", the first code replaces the character before the cursor (朋), then the formed character "友" inserted at the position of the cursor.
    insert-mode-with-overtype-extension.gif

@yowynn
Copy link

yowynn commented Aug 26, 2021

Tried to play around a bit with overtype and Chinese letters, the behaviour that I'm getting is that:

Screen.Recording.2021-07-26.at.11.46.21.mov
Could you share a video with the issue to better understand which is the incorrect behaviour?

(on VSCode version: 1.58.0)

type a a fullwidth character

Untitled-1.2021-08-26.11-29-51.mp4

@TheV360
Copy link

TheV360 commented Oct 8, 2021

I've been having a related problem with Visual Studio Code, where if I open the Windows emoji picker (:window:+;) and select an emoji, it would insert the emoji twice and overwrite surrounding text. I tracked it down to (the unmaintained version of) this extension with an Extension Bisect. I think this is because both the Chinese input system and emoji picker are IMEs?

Here's a video of me triggering the bug:

2021-10-07_20-10-31_overtype_issue.mp4

First, I insert an emoji without the extension active, then I try it with the extension active. This is without actually activating the Overtype mode -- it affects the text editor as long as the extension is enabled.

@DrMerfy
Copy link
Owner Author

DrMerfy commented Oct 23, 2021

Thanks for the captures, everyone!
Sorry that I've taken such a long time to respond. This looks like a very real problem, if I find some time I'll take a closer look into it, but next months are going to be as busy as well.

Just a small reminder, that I still notice what is happening on this extension, I've just not found the time to play around.
If someone has any solution, I'd gladly take a look :D

@Daniel-Chin
Copy link

Typing a wide-char symbol also eats the previous ascii character when overtype is off.

e.g.
"asdf"
[Type one "。"]
becomes "asd。。"

@changlichun
Copy link

@DrMerfy I look into the code and I feel it is because the misbehavier of the default command 'default:type'. It looks like the command 'default:type' behavie different from the direct type.
And I occasionally find that this extension works correctly in an elder version of vscode (Version: 1.40.2 (system setup) Commit: f359dd69833dd8800b54d458f6d37ab7c78df520 Date: 2019-11-25T14:54:45.096Z)
Video_2022-05-02_165310
I'm sorry that I do not have enough time to look into the vscode's source code, and still no solution.
Thank you very much for your patient work.

@UniversesAurora
Copy link

UniversesAurora commented Jun 1, 2022

Yes it seems to be a bug of vscode. I created a simple extension only overwrite default type command and call default type using executeCommand in it, and this problem still occurred.

Also i found that the problem only occurred on Windows, on macos or linux it seems to work just fine.

@FrankSFLYS
Copy link

and 后, becomes ,,

@ParadoxV5
Copy link

But VSCode now claims that they’ve fixed the problem on their side.

Perhaps what we need to do is switching to their new editor.experimentalEditContextEnabled.

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

10 participants