From e2e13f1831a71b558b3625c4ecf3d35100236870 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 14 Nov 2012 22:17:56 -0800 Subject: [PATCH] ansi-term escape-char fix * lisp/term.el (ansi-term): Don't let C-x escape-char binding clobber the more standard C-c binding. Fixes: debbugs:12842 --- lisp/ChangeLog | 5 +++++ lisp/term.el | 15 ++++++++++----- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index f78240cdced..01ccb886434 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2012-11-15 Glenn Morris + + * term.el (ansi-term): Don't let C-x escape-char binding + clobber the more standard C-c binding. (Bug#12842) + 2012-11-15 Stefan Monnier * emacs-lisp/gv.el (setf): Fix debug spec for multiple assignments diff --git a/lisp/term.el b/lisp/term.el index e6466b8fa95..d6acaef1ae9 100644 --- a/lisp/term.el +++ b/lisp/term.el @@ -4178,11 +4178,16 @@ the process. Any more args are arguments to PROGRAM." (term-mode) (term-char-mode) - ;; I wanna have find-file on C-x C-f -mm - ;; your mileage may definitely vary, maybe it's better to put this in your - ;; .emacs ... - - (term-set-escape-char ?\C-x) + ;; Historical baggage. A call to term-set-escape-char used to not + ;; undo any previous call to t-s-e-c. Because of this, ansi-term + ;; ended up with both C-x and C-c as escape chars. Who knows what + ;; the original intention was, but people could have become used to + ;; either. (Bug#12842) + (let (term-escape-char) + ;; I wanna have find-file on C-x C-f -mm + ;; your mileage may definitely vary, maybe it's better to put this in your + ;; .emacs ... + (term-set-escape-char ?\C-x)) (switch-to-buffer term-ansi-buffer-name)) -- 2.39.2