Character Overlap during Korean IME Composition #6923

Closed
opened 2026-01-31 00:50:35 +00:00 by claunia · 12 comments
Owner

Originally created by @KennethanCeyer on GitHub (Mar 17, 2020).

Originally assigned to: @leonMSFT on GitHub.

Environment

Windows version

Microsoft Windows [Version 10.0.18362.720]

Terminal version

Version: 0.10.761.0

Steps to reproduce

  1. Open "Terminal" app
  2. Type "테스트" (It means test in Korean)
  3. You can probably see the letters overlapping

Expected behavior

Rather than a long explanation, I'd rather attach the behavior of another operating system terminal.

macos_terminal

In the case of MacOS, the cursor is positioned under the letter being combined during the Korean language composition process, and there is no collision of letters.

linux_terminal

In the Ubuntu 18.04 X Window system environment, if the same operation is performed in the terminal, You can expect that Hangul characters are under the composition process in a cursor shape. And the Hangul characters do not overlap.

Actual behavior

windows_terminal

In Version: 0.10.761.0, there is a problem that the Korean characters are overlapped as shown in the picture above.

If this problem is expected to be relatively minor by the core development team, please give a hint to the source code that is expected to be a problem so that I can give you a PR.

Originally created by @KennethanCeyer on GitHub (Mar 17, 2020). Originally assigned to: @leonMSFT on GitHub. <!-- 🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨 I ACKNOWLEDGE THE FOLLOWING BEFORE PROCEEDING: 1. If I delete this entire template and go my own path, the core team may close my issue without further explanation or engagement. 2. If I list multiple bugs/concerns in this one issue, the core team may close my issue without further explanation or engagement. 3. If I write an issue that has many duplicates, the core team may close my issue without further explanation or engagement (and without necessarily spending time to find the exact duplicate ID number). 4. If I leave the title incomplete when filing the issue, the core team may close my issue without further explanation or engagement. 5. If I file something completely blank in the body, the core team may close my issue without further explanation or engagement. All good? Then proceed! --> <!-- This bug tracker is monitored by Windows Terminal development team and other technical folks. **Important: When reporting BSODs or security issues, DO NOT attach memory dumps, logs, or traces to Github issues**. Instead, send dumps/traces to secure@microsoft.com, referencing this GitHub issue. If this is an application crash, please also provide a Feedback Hub submission link so we can find your diagnostic data on the backend. Use the category "Apps > Windows Terminal (Preview)" and choose "Share My Feedback" after submission to get the link. Please use this form and describe your issue, concisely but precisely, with as much detail as possible. --> # Environment **Windows version** ``` Microsoft Windows [Version 10.0.18362.720] ``` **Terminal version** ``` Version: 0.10.761.0 ``` # Steps to reproduce <!-- A description of how to trigger this bug. --> 1. Open "Terminal" app 2. Type `"테스트"` (It means test in Korean) 3. You can probably see the letters overlapping # Expected behavior <!-- A description of what you're expecting, possibly containing screenshots or reference material. --> Rather than a long explanation, I'd rather attach the behavior of another operating system terminal. <img width="682" alt="macos_terminal" src="https://user-images.githubusercontent.com/7090315/76889435-ee5c5d80-68c8-11ea-89c2-f12949d95c97.png"> In the case of MacOS, the cursor is positioned under the letter being combined during the Korean language composition process, and there is no collision of letters. ![linux_terminal](https://user-images.githubusercontent.com/7090315/76889546-22378300-68c9-11ea-9206-87d8362d4497.jpg) In the Ubuntu 18.04 X Window system environment, if the same operation is performed in the terminal, You can expect that Hangul characters are under the composition process in a cursor shape. And the Hangul characters do not overlap. # Actual behavior <!-- What's actually happening? --> ![windows_terminal](https://user-images.githubusercontent.com/7090315/76889842-ab4eba00-68c9-11ea-9876-a05d4181df4a.png) In `Version: 0.10.761.0`, there is a problem that the Korean characters are overlapped as shown in the picture above. If this problem is expected to be relatively minor by the core development team, please give a hint to the source code that is expected to be a problem so that I can give you a PR.
Author
Owner

@jdebp commented on GitHub (Mar 17, 2020):

A data point: pasting in the same character sequence from the clipboard did not cause such an effect when I tried it, out of curiosity. I didn't try a Hangeul input method, though.

@jdebp commented on GitHub (Mar 17, 2020): A data point: pasting in the same character sequence from the clipboard did not cause such an effect when I tried it, out of curiosity. I didn't try a Hangeul input method, though.
Author
Owner

@KennethanCeyer commented on GitHub (Mar 17, 2020):

@jdebp Thanks for the additional comments! This problem is reproduced in the process of combining IME Hangul characters, so it is difficult to reproduce it by copying the clipboard.

@KennethanCeyer commented on GitHub (Mar 17, 2020): @jdebp Thanks for the additional comments! This problem is reproduced in the process of combining IME Hangul characters, so it is difficult to reproduce it by copying the clipboard.
Author
Owner

@KennethanCeyer commented on GitHub (Mar 17, 2020):

If you test by typing the letters ㅌ, ㅔ, ㅅ, ㅡ, ㅌ, ㅡ in order, you can check the problem.

@KennethanCeyer commented on GitHub (Mar 17, 2020): If you test by typing the letters ㅌ, ㅔ, ㅅ, ㅡ, ㅌ, ㅡ in order, you can check the problem.
Author
Owner

@leonMSFT commented on GitHub (Mar 17, 2020):

So at first glance, it seems like the TSFInputControl is getting its set of LayoutRequested events before the Terminal manages to update its cursor, leading to the TextBlock staying in the same place when it should have moved over to where the cursor currently is. If you then type one extra character after the first overlapping keypress, the LayoutRequested will fire again, and will update the TextBlock to the correct position of the cursor.

What's funny is that while debugging this by building it in Visual Studio and running it with the debugger, my breakpoints slow the events down enough that sometimes the Terminal updates its cursor before the LayoutRequested event is received, which makes the text not overlap.

@KennethanCeyer I think the fix might be simple, depending on how difficult it is to figure out when we should be re-drawing where the TextBlock should be, instead of relying on LayoutRequested to do it. If you're willing to take a stab at it, let me know and I can answer questions if you have any! 😄

@leonMSFT commented on GitHub (Mar 17, 2020): So at first glance, it seems like the `TSFInputControl` is getting its set of `LayoutRequested` events before the Terminal manages to update its cursor, leading to the `TextBlock` staying in the same place when it should have moved over to where the cursor currently is. If you then type one extra character after the first overlapping keypress, the `LayoutRequested` will fire again, and will update the TextBlock to the correct position of the cursor. What's funny is that while debugging this by building it in Visual Studio and running it with the debugger, my breakpoints slow the events down enough that _sometimes_ the Terminal updates its cursor before the `LayoutRequested` event is received, which makes the text not overlap. @KennethanCeyer I think the fix might be simple, depending on how difficult it is to figure out when we should be re-drawing where the `TextBlock` should be, instead of relying on `LayoutRequested` to do it. If you're willing to take a stab at it, let me know and I can answer questions if you have any! 😄
Author
Owner

@KennethanCeyer commented on GitHub (Mar 18, 2020):

@leonMSFT
Thank you for a detailed description. Now it's just a matter of reading the contribution documentation and looking at the code!

@KennethanCeyer commented on GitHub (Mar 18, 2020): @leonMSFT Thank you for a detailed description. Now it's just a matter of reading the contribution documentation and looking at the code!
Author
Owner

@leonMSFT commented on GitHub (Mar 23, 2020):

Hi @KennethanCeyer, just checking in to see where you're at with this bug, if you haven't had too many chances to make much progress on it, I could pick up from where you left off. Otherwise if you're close to a PR disregard me! 😄 I'm just tracking this bug more closely than others because it's marked as a P1 bug.

@leonMSFT commented on GitHub (Mar 23, 2020): Hi @KennethanCeyer, just checking in to see where you're at with this bug, if you haven't had too many chances to make much progress on it, I could pick up from where you left off. Otherwise if you're close to a PR disregard me! 😄 I'm just tracking this bug more closely than others because it's marked as a P1 bug.
Author
Owner

@KennethanCeyer commented on GitHub (Mar 24, 2020):

@leonMSFT
Yes, I see it on my side, but it takes about 7 days to respond.
Since it's P1, I think I should not hold onto it and become a block
If you can fix it, please proceed immediately. I'm sorry I seemed to be in the way.

@KennethanCeyer commented on GitHub (Mar 24, 2020): @leonMSFT Yes, I see it on my side, but it takes about 7 days to respond. Since it's P1, I think I should not hold onto it and become a block If you can fix it, please proceed immediately. I'm sorry I seemed to be in the way.
Author
Owner

@leonMSFT commented on GitHub (Mar 24, 2020):

Please don’t apologize! You were definitely not a blocker, as I was working on some other bugs in the meantime anyway. I was happy to let you take a look at the bug since you expressed some interest 🙂 I just figured I would check in to see how you were doing and perhaps offer my assistance. Thank you for reporting the bug and looking into it and providing your findings in the meantime though, I really appreciate it! 👍🏻

@leonMSFT commented on GitHub (Mar 24, 2020): Please don’t apologize! You were definitely not a blocker, as I was working on some other bugs in the meantime anyway. I was happy to let you take a look at the bug since you expressed some interest 🙂 I just figured I would check in to see how you were doing and perhaps offer my assistance. Thank you for reporting the bug and looking into it and providing your findings in the meantime though, I really appreciate it! 👍🏻
Author
Owner

@ghost commented on GitHub (Apr 22, 2020):

:tada:This issue was addressed in #5135, which has now been successfully released as Windows Terminal Preview v0.11.1121.0.🎉

Handy links:

@ghost commented on GitHub (Apr 22, 2020): :tada:This issue was addressed in #5135, which has now been successfully released as `Windows Terminal Preview v0.11.1121.0`.:tada: Handy links: * [Release Notes](https://github.com/microsoft/terminal/releases/tag/v0.11.1121.0) * [Store Download](https://www.microsoft.com/store/apps/9n0dx20hk701?cid=storebadge&ocid=badge)
Author
Owner

@sykwon66 commented on GitHub (Nov 22, 2021):

I see this same problem in version 1.11.2921.0 when Korean typing was made in Cygwin bash.
Both windows 10 and 11 show same problem.
No issue with cmd and PowerShell.
Attached the picture when problem happened (I was typing "한글을 사용하다 보며")
windows terminal cygwin korean char input overlapping
.

@sykwon66 commented on GitHub (Nov 22, 2021): I see this same problem in version 1.11.2921.0 when Korean typing was made in Cygwin bash. Both windows 10 and 11 show same problem. No issue with cmd and PowerShell. Attached the picture when problem happened (I was typing "한글을 사용하다 보며") ![windows terminal cygwin korean char input overlapping](https://user-images.githubusercontent.com/94843514/142865406-7a85f745-4ccf-401f-8152-7e9249466d81.png) .
Author
Owner

@KennethanCeyer commented on GitHub (Nov 24, 2021):

I also found the bug reproducible in 1.11.2921.0. as mentioned by @sykwon66

image

@KennethanCeyer commented on GitHub (Nov 24, 2021): I also found the bug reproducible in `1.11.2921.0`. as mentioned by @sykwon66 ![image](https://user-images.githubusercontent.com/7090315/143213086-49388788-ebf0-40cc-916a-4cece7409360.png)
Author
Owner

@sykwon66 commented on GitHub (May 9, 2022):

Seems fixed in 1.12.10982.0.
However there is actually very short time being overlapped still remained.

Previous: chars overlapped and stayed there.
Now: momentarilly overlapped and splits..
Fixed but annoying to see.

@sykwon66 commented on GitHub (May 9, 2022): Seems fixed in 1.12.10982.0. However there is actually very short time being overlapped still remained. Previous: chars overlapped and stayed there. Now: momentarilly overlapped and splits.. Fixed but annoying to see.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#6923