This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

control left in emacs in rxvt


I'm running rxvt (2.7.10) as a native windows app (no X server) and
within rxvt I'm running emacs -nw (21.2.1) I've googled around trying
to find out how I can make emacs see control left arrow as <C-left> so
that all my emacs keymaps in various modes work properly.

I was able to remap control-left in bash by adding this line to my
~/.inputrc file

"\eOd": backward-word

and I know I 'could' add 
(global-set-key  [(meta O) (d)] 'backward-word)
to my .emacs

however I set various keys to behave differently in different modes,
so I'd have to go and define each key twice. Once when emacs sees it
as [(control left)] and another for rxvt which see's it as 
[(meta O) (d)] This is going to be a big pain.

Is there a way for me to make it so that when I do a Control-h k
(describe-key) and hit control left - emacs will see that key as
<C-left> rather than "ESC O d"
It already sees left as <left>

alternatively (although this seems like a hack) do you know of a way
in emacs to bind one key sequence to look like another - i.e. I don't
want to map "ESC O d" to an emacs function, I want to map it so that
when you press it you do the function mapped to <C-left>

I also see this when I ssh to a redhat linux machine and run emacs
there (all in rxvt) I'm hoping when I solve the first problem I'll
solve the second at the same time.

I tried to read up on termcap and terminfo, but saw there were only
key sequences for Shift left and not control left.

Any help is greatly appreciated!

Alex.

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]