Created
February 28, 2012 15:16
-
-
Save autotelicum/1933036 to your computer and use it in GitHub Desktop.
Acme patch: Add Ctrl-keys in the same way as Cmd-keys for copy, paste, cut and undo.
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
--- text.c 2012-02-28 21:29:19.000000000 +0700 | |
+++ text.bak.c 2012-02-28 20:51:03.000000000 +0700 | |
@@ -745,12 +745,10 @@ | |
q0++; | |
textshow(t, q0, q0, TRUE); | |
return; | |
- case 0x03: /* ^C: copy FIX */ | |
case Kcmd+'c': /* %C: copy */ | |
typecommit(t); | |
cut(t, t, nil, TRUE, FALSE, nil, 0); | |
return; | |
- case 0x1A: /* ^Z: undo FIX */ | |
case Kcmd+'z': /* %Z: undo */ | |
typecommit(t); | |
undo(t, nil, nil, TRUE, 0, nil, 0); | |
@@ -779,7 +777,6 @@ | |
} | |
/* cut/paste must be done after the seq++/filemark */ | |
switch(r){ | |
- case 0x18: /* ^X: cut FIX */ | |
case Kcmd+'x': /* %X: cut */ | |
typecommit(t); | |
if(t->what == Body){ | |
@@ -790,7 +787,6 @@ | |
textshow(t, t->q0, t->q0, 1); | |
t->iq1 = t->q0; | |
return; | |
- case 0x16: /* ^V: paste FIX */ | |
case Kcmd+'v': /* %V: paste */ | |
typecommit(t); | |
if(t->what == Body){ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment