Add keybinding: something like moveCursorLeft, moveCursorRight #5393

Closed
opened 2026-01-31 00:12:23 +00:00 by claunia · 3 comments
Owner

Originally created by @Sopharizer on GitHub (Dec 5, 2019).

Description of the new feature/enhancement

Ctrl+F/X/N/P etc. work in the wt by default (like emacs keybindings). However, Ctrl+B didn't work, and there is no property which can set keybindings for cursor moving.

Proposed technical implementation details (optional)

I'm not sure this feature can easily be implemented, for example, by modifying AppKeyBindingsSerialization.cpp, but I think there's many users familiar with emacs keybindings (including me).

Originally created by @Sopharizer on GitHub (Dec 5, 2019). <!-- 🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨 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! --> # Description of the new feature/enhancement <!-- A clear and concise description of what the problem is that the new feature would solve. Describe why and how a user would use this new functionality (if applicable). --> Ctrl+F/X/N/P etc. work in the wt by default (like emacs keybindings). However, Ctrl+B didn't work, and there is no property which can set keybindings for cursor moving. # Proposed technical implementation details (optional) <!-- A clear and concise description of what you want to happen. --> I'm not sure this feature can easily be implemented, for example, by modifying AppKeyBindingsSerialization.cpp, but I think there's many users familiar with emacs keybindings (including me).
claunia added the Issue-FeatureNeeds-Tag-Fix labels 2026-01-31 00:12:23 +00:00
Author
Owner

@DHowett-MSFT commented on GitHub (Dec 5, 2019):

Cursor movement is the responsibility of the shell you are using. If that shell is PowerShell, use the PSReadline options to set up those motions. If you’re using bash, configure your inputrc. If you’re using zsh, use bindkey. If you’re using cmd, we aren’t going to add those bindings (sorry.)

@DHowett-MSFT commented on GitHub (Dec 5, 2019): Cursor movement is the responsibility of the shell you are using. If that shell is PowerShell, use the PSReadline options to set up those motions. If you’re using bash, configure your `inputrc`. If you’re using zsh, use `bindkey`. If you’re using cmd, we aren’t going to add those bindings (sorry.)
Author
Owner

@Sopharizer commented on GitHub (Dec 5, 2019):

I'm using zsh(wsl).
Executing bindkey command, The output was
......
"^B" backward-char
......
and Ctrl+B still didn't work. Ctrl+B did work if I use FluentTerminal as a terminal emulator, so I thought wt could be responsible for that.

@Sopharizer commented on GitHub (Dec 5, 2019): I'm using zsh(wsl). Executing `bindkey` command, The output was `......` `"^B" backward-char` `......` and Ctrl+B still didn't work. Ctrl+B did work if I use FluentTerminal as a terminal emulator, so I thought wt could be responsible for that.
Author
Owner

@9at8 commented on GitHub (Apr 1, 2020):

@Sopharizer I was able to achieve this by setting PSReadline edit mode option and saving that to a configuration file.

@9at8 commented on GitHub (Apr 1, 2020): @Sopharizer I was able to achieve this by [setting PSReadline edit mode option](https://github.com/PowerShell/PSReadLine/blob/master/docs/Set-PSReadLineOption.md#-editmode) and [saving that to a configuration file](https://devblogs.microsoft.com/scripting/understanding-the-six-powershell-profiles).
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#5393