Last active
January 23, 2018 07:20
-
-
Save skywind3000/4efdb6975821b180310174a2e7dc9581 to your computer and use it in GitHub Desktop.
Patch to fix Backspace for Windows Console Vim
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/os_win32.c b/src/os_win32.c | |
index f2fd808e9..323bdcd7c 100644 | |
--- a/src/os_win32.c | |
+++ b/src/os_win32.c | |
@@ -807,6 +807,7 @@ static const struct | |
{ VK_NEXT, TRUE, 'Q', '\322', 'v', '\323', }, /*PgDn*/ | |
{ VK_INSERT,TRUE, 'R', '\324', '\325', '\326', }, | |
{ VK_DELETE,TRUE, 'S', '\327', '\330', '\331', }, | |
+ { VK_BACK, TRUE, '\x7f', 0, 0, 0, }, | |
{ VK_SNAPSHOT,TRUE, 0, 0, 0, 'r', }, /*PrtScrn*/ | |
diff --git a/src/term.c b/src/term.c | |
index 989d6b7af..ffc15b506 100644 | |
--- a/src/term.c | |
+++ b/src/term.c | |
@@ -633,6 +633,7 @@ static struct builtin_term builtin_termcaps[] = | |
{K_K7, "\316\366"}, | |
{K_K8, "\316\372"}, | |
{K_K9, "\316\376"}, | |
+ {K_BS, "\316\x7f"}, | |
# endif | |
# if defined(VMS) || defined(ALL_BUILTIN_TCAPS) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
int main(void) | |
{ | |
return 0; | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
hehe