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

Add support for Ctrl+# keys #4938

Merged
4 commits merged into from
Mar 18, 2020
Merged

Add support for Ctrl+# keys #4938

4 commits merged into from
Mar 18, 2020

Conversation

zadjii-msft
Copy link
Member

Summary of the Pull Request

Fixes the Ctrl+Num keys in both conhost and the Terminal. These keys are supposed to be mapped to specific characters according to this doc. Now we actually handle them correctly.

PR Checklist

Validation Steps Performed

  • Ran test
  • tested in gnome-terminal with showkeys -a
  • tested in conhost with showkeys -a
  • tested in Windows Terminal with showkeys -a

@zadjii-msft zadjii-msft added Product-Conhost For issues in the Console codebase Area-Input Related to input processing (key presses, mouse, etc.) Area-VT Virtual Terminal sequence support labels Mar 16, 2020
@DHowett-MSFT
Copy link
Contributor

@msftbot merge this in 1 minute

@ghost ghost added the AutoMerge Marked for automatic merge by the bot when requirements are met label Mar 16, 2020
@ghost
Copy link

ghost commented Mar 16, 2020

Hello @DHowett-MSFT!

Because you've given me some instructions on how to help merge this pull request, I'll be modifying my merge approach. Here's how I understand your requirements for merging this pull request:

  • I won't merge this pull request until after the UTC date Mon, 16 Mar 2020 17:00:52 GMT, which is in 1 minute

If this doesn't seem right to you, you can tell me to cancel these instructions and use the auto-merge policy that has been configured for this repository. Try telling me "forget everything I just told you".

@DHowett-MSFT DHowett-MSFT removed the AutoMerge Marked for automatic merge by the bot when requirements are met label Mar 16, 2020
@DHowett-MSFT
Copy link
Contributor

(The test itself seems to be failing?)

@zadjii-msft
Copy link
Member Author

(I'm holding this till I merge #4988 and #4964)

@DHowett-MSFT DHowett-MSFT added the AutoMerge Marked for automatic merge by the bot when requirements are met label Mar 18, 2020
@ghost
Copy link

ghost commented Mar 18, 2020

Hello @DHowett-MSFT!

Because this pull request has the AutoMerge label, I will be glad to assist with helping to merge this pull request once all check-in policies pass.

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 (@msftbot) and give me an instruction to get started! Learn more here.

@ghost ghost merged commit f7d106d into master Mar 18, 2020
DHowett-MSFT pushed a commit that referenced this pull request Mar 19, 2020
## Summary of the Pull Request

Fixes the <kbd>Ctrl+Num</kbd> keys in both conhost and the Terminal. These keys are supposed to be mapped to specific characters according to [this doc](https://vt100.net/docs/vt220-rm/table3-5.html). Now we actually handle them correctly.

## PR Checklist
* [x] Closes #3507
* [x] I work here
* [x] Tests added/passed
* [n/a] Requires documentation to be updated

## Validation Steps Performed

* Ran test
* tested in `gnome-terminal` with `showkeys -a`
* tested in conhost with `showkeys -a`
* tested in Windows Terminal with `showkeys -a`

(cherry picked from commit f7d106d)
@zadjii-msft zadjii-msft deleted the dev/migrie/b/3507-ctrl-#-keys branch March 19, 2020 13:33
@Zenexer
Copy link

Zenexer commented Mar 20, 2020

@zadjii-msft Does this also send the same codes when Shift is held? Some applications--e.g., mosh--advise users to press a combination such as Ctrl + ^ to send ^^, which is often interpreted as requiring that Shift be held even though it's not necessary. Ctrl + Shift + # is bound by default in some terminals (including Windows Terminal), but some users may wish to unbind them, in which case they should send the correct codes.

@ghost
Copy link

ghost commented Mar 20, 2020

🎉Windows Terminal Preview v0.10.781.0 has been released which incorporates this pull request.:tada:

Handy links:

This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Input Related to input processing (key presses, mouse, etc.) Area-VT Virtual Terminal sequence support AutoMerge Marked for automatic merge by the bot when requirements are met Product-Conhost For issues in the Console codebase
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ctrl + # not being processed by Bash correctly
4 participants