-
Notifications
You must be signed in to change notification settings - Fork 8.4k
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
Allow Emoji composition to be seen in the TSF TextBlock #4836
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just to be sure- now all of C, J, K and Emoji work properly? 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oops, wrong account.
I tested all four out again, all of them seem to work as expected 🤞 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure ¯\_(ツ)_/¯
@leonMSFT does my boy "¯\_(ツ)_/¯" still work with the emoji picker too? |
oh no the arm got chopped off |
Hello @leonMSFT! Because this pull request has the p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (
|
Summary of the Pull Request
Emoji composition was only being shown one letter at a time. This is because of the way I expected
CoreTextTextUpdatingEventArgs.Range
to be provided to TSFInputControl during composition (for Chinese/Japanese IME). Emoji IME composition gives theStartCaretPosition
as the same asEndCaretPosition
, unlike how for Chinese/Japanese IME,StartCaretPosition
is usually the start of the composition andEndCaretPosition
is the latest character in the composition. The solution is to change the_inputBuffer.substr()
call to simply grab all of the buffer starting from_activeTextStart
. This way I can ensure that I grab all of the "active text", instead of trusting the givenargs.Range
to tell me the active text.PR Checklist
Validation Steps Performed
Chinese, Japanese, Korean, Emoji composition performed. Emoji selection through pointer also performed.