Repository navigation
Quick pick: match the Hangul syllable an IME is still composing - #350141
Open
wonjang (wonjangcloud9) wants to merge 1 commit into
Open
wonjang (wonjangcloud9) wants to merge 1 commit into
wonjang (wonjangcloud9) wants to merge 1 commit into
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues remain for the change enabling quick-pick matching of unfinished Hangul characters.
No open issues 🎉
What changed in this PR
Addresses #192789 by letting quick-pick word matching recognize an unfinished final Hangul character, so Korean queries can find commands before the IME completes the syllable.
Changes:
- Compares Korean keystroke prefixes for the final query character while preserving existing matching for earlier characters.
- Adds regression cases for partial consonants, syllable extensions, word boundaries, and non-matches.
No actionable findings remain. Reported tests used a Bun/Mocha shim rather than the repository’s test runner.
| File | Description |
|---|---|
| src/vs/base/test/common/filters.test.ts | Adds positive and negative partial-Hangul matching cases. |
| src/vs/base/common/filters.ts | Adds final-character Hangul prefix matching and includes partial matches in highlight ranges. |
Review effort: Balanced
Author
|
@microsoft-github-policy-service agree |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #192789
Typing Korean builds each syllable from keystrokes, so while you type the last character of a query is usually unfinished. To reach
터미널, the box showsㅌ, then터, then털(the IME's guess) before the next syllable. TodaymatchesWordsonly finds터미널once터is complete, so the Command Palette shows nothing afterㅌ. Naver and Google treat the last character as partial (see the issue).Change (
src/vs/base/common/filters.ts): in_matchesWordsCompute, the last character of the query also matches a target Hangul syllable that it starts. "Starts" is judged by the keystrokesgetKoreanAltCharsalready produces for the Korean-on-QWERTY matching:ㅌx터xj미al밋alt고rh과rhk고+ㅏinto과)ㄱr나skOnly the last query character gets this, so
ㅌ미does not match터미널. Characters before it are complete and still have to match exactly. The check returns early unless the target character is a Hangul syllable (U+AC00–U+D7A3), so non-Korean labels skip the extra work.Not covered: a final consonant the IME later moves to the next syllable (typing
가고shows각for a moment). That needs the query's last two characters re-split, so I left it out of this change.Tests (
filters.test.ts,WordFilter):ㅌ→터미널: 새 터미널 만들기,커미→커밋,고→과일,새 ㅌ→ the second터미널, and two negatives (ㅌ미/터미널,ㄱ/나). I ranfilters.test.tsandnaturalLanguage/korean.test.tsunder bun with a small mocha shim, not the repo's runner. With the change: 41 pass, 1 skipped (perf). Without it: the newWordFiltercases fail (ㅌ didn't match 터미널: 새 터미널 만들기).🤖 Generated with Claude Code