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]

Re: Help with special bash key bindings ("Ctrl+Left", "Ctrl+Right",etc.)


Milan,

To find out the exact sequence a key produces (on the bash command line or
in vi), press Ctrl-V and the key.  HTH,
	Igor
P.S. Oh, and xterm does have different key bindings than the command
prompt.

On Tue, 22 Oct 2002, Randall R Schulz wrote:

> Milan,
>
> Most everything you need to know is in the READLINE section of the BASH
> manual "page" ("man bash" or "pinfo bash"). The only interesting oversight
> that I'm aware of is the "paste-from-clipboard" action which will, as the
> name suggests, past the first line of the clipboard (up to but not
> including the first newline) into the current input line.
>
> Key bindings for the arrow keys don't carry information about the control
> key, but they are modified by the ALT key. You might want to experiment
> with the "od" command to see what sequences are produced by different keys
> (Fn, arrow keys, the insert, home... cluster).
>
> Note, too, that different sequences result for _some_ of the keys in
> console vs. RXVT windows (given that fact, I'd avoid assuming that xterm
> matches either of them exactly, though it might--I don't know).
>
> Good luck.
>
> Randall Schulz
> Mountain View, CA USA
>
> At 21:25 2002-10-22, Milan Gardian wrote:
> >Hi,
> >
> >could anybody please help me with setup of my bash (readline) .inputrc
> >file - I'd like to bind the following keys to the following actions
> >(usual Windows editor associations):
> >
> >?: kill-word      # Ctrl-Del
> >?: backward-word  # Ctrl-Left (left is "\e[D")
> >?: forward-word   # Ctrl-Right (left is "\e[C")
> >
> >Thanks for any suggestions!
> >
> >Cheers,
> >
> >Milan

-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_		pechtcha@cs.nyu.edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor@watson.ibm.com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"Water molecules expand as they grow warmer" (C) Popular Science, Oct'02, p.51


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.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]