From 152b1063752680631fdb3ba863ef1f5d1ca474ec Mon Sep 17 00:00:00 2001 From: Andrew Schwartzmeyer Date: Fri, 8 Jul 2016 16:19:05 -0700 Subject: [PATCH] Use Control-F/B for Right/Left arrow --- .../host/msh/ConsoleHostUserInterface.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/Microsoft.PowerShell.ConsoleHost/host/msh/ConsoleHostUserInterface.cs b/src/Microsoft.PowerShell.ConsoleHost/host/msh/ConsoleHostUserInterface.cs index 1468558633..020ddc2799 100644 --- a/src/Microsoft.PowerShell.ConsoleHost/host/msh/ConsoleHostUserInterface.cs +++ b/src/Microsoft.PowerShell.ConsoleHost/host/msh/ConsoleHostUserInterface.cs @@ -1879,7 +1879,8 @@ namespace Microsoft.PowerShell continue; } - if (keyInfo.Key == ConsoleKey.LeftArrow) + if (keyInfo.Key == ConsoleKey.LeftArrow + || (keyInfo.Key == ConsoleKey.B && keyInfo.Modifiers.HasFlag(ConsoleModifiers.Control))) { if (Console.CursorLeft > cursorLeft) { @@ -1889,7 +1890,8 @@ namespace Microsoft.PowerShell continue; } - if (keyInfo.Key == ConsoleKey.RightArrow) + if (keyInfo.Key == ConsoleKey.RightArrow + || (keyInfo.Key == ConsoleKey.F && keyInfo.Modifiers.HasFlag(ConsoleModifiers.Control))) { if (Console.CursorLeft < cursorLeft + s.Length) {