From: Robert Thorpe <rt@robertthorpeconsulting.com>
To: help-gnu-emacs@gnu.org
Subject: Re: Possible to bind C-o to some function in an ansi-term? (Add something to term-mode-hook?)
Date: Tue, 11 Aug 2015 02:37:56 +0100 [thread overview]
Message-ID: <87a8tyfvuz.fsf@robertthorpeconsulting.com> (raw)
In-Reply-To: <87h9o9b5j9.fsf@nl106-137-147.student.uu.se> (message from Emanuel Berg on Sun, 09 Aug 2015 03:43:22 +0200)
Emanuel Berg <embe8573@student.uu.se> writes:
> Dan Espen <despen@verizon.net> writes:
>
>> I think the OP may need to do the binding in
>> term-mode-hook. But I confess, I don't really
>> understand term.el and I haven't tried. It has
>> a term-mode-map and some other maps that just
>> confuse me.
>
> OK - well, it doesn't work just setting the
> term-mode-map, probably because the shell intercepts
> the keystrokes and this is the whole idea with the
> mode. Perhaps the OP can use 'M-x shell RET' where
> keys are setup like everwhere else?
As far as I know, and that's not very far....
Term-mode and ansi-term are now very similar. They both have two modes
"character" and "line". "Line" is like *shell*, each line is sent at
once to the shell. "Character" is like a terminal, each character is
sent. The only difference between ansi-term and term-mode is the escape
character (C-c for term-mode and both C-c and C-x for ansi-term). So,
you can over-ride keybindings quite easily using term-mode-map in line
mode but not in character mode. In character mode term-raw-map is used.
That looks like something you wouldn't want to tinker with.
BR,
Robert Thorpe
prev parent reply other threads:[~2015-08-11 1:37 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-08-06 6:34 Possible to bind C-o to some function in an ansi-term? (Add something to term-mode-hook?) Chris Seberino
2015-08-07 22:36 ` Emanuel Berg
[not found] ` <mailman.7965.1438987218.904.help-gnu-emacs@gnu.org>
2015-08-08 1:28 ` Dan Espen
2015-08-09 1:43 ` Emanuel Berg
2015-08-11 1:37 ` Robert Thorpe [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87a8tyfvuz.fsf@robertthorpeconsulting.com \
--to=rt@robertthorpeconsulting.com \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.