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

input: handle dead keys #3430

Merged
merged 2 commits into from
Aug 23, 2021
Merged

input: handle dead keys #3430

merged 2 commits into from
Aug 23, 2021

Conversation

Eugeny
Copy link
Member

@Eugeny Eugeny commented Aug 22, 2021

Fixes #2151
This adds extra handling to avoid canceling keydown events dead keys, since canceling a dead key's own keydown will cancel the future keydown for the combined character.

The typical event flow for e.g. Swedish Tilde + Forward Slash is:

  • While canceling keydown (current):
    image

  • Without canceling keydown (fixed):
    image

For clarity, we want to let through the next keydown event that is responsible for a future keypress/input (so not just the "next" one since it might be a modifier key), hence the order of the checks.

@Tyriar Tyriar added this to the 4.14.0 milestone Aug 23, 2021
Copy link
Member

@Tyriar Tyriar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change looks fine, I'll assume you're better off testing this one than me 👍

@Tyriar Tyriar merged commit a706e01 into xtermjs:master Aug 23, 2021
@Tyriar
Copy link
Member

Tyriar commented Aug 23, 2021

@Eugeny does this fix microsoft/vscode#82489?

@Eugeny
Copy link
Member Author

Eugeny commented Aug 23, 2021

I suppose it might, but I have only tested that specific tilde combination problem so far.

Edit: yep looks like it's the same thing going on but in a different keyboard layout. I can test tonight.

@Eugeny Eugeny deleted the dead-key-support branch August 23, 2021 14:38
@Eugeny
Copy link
Member Author

Eugeny commented Aug 24, 2021

Yep, that one's fixed too.

This pull request was closed.
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

Successfully merging this pull request may close these issues.

Scandinavian keyboard layout can't handle input tilde (~)
2 participants