: bindkey in tcsh

: bindkey in tcsh

Post by samuel kok » Sun, 15 Oct 2000 04:00:00



Hello. Just a basic question about key bindings in tcsh.
How could I bind "ctrl-right-arrow" to "forward-word" ?

I know this is not very "vi-ish" nor "emacs-ish", but I'm quite used to
such key-combo.
I tried different syntaxes unsuccessully.

Thx.

Sam.

 
 
 

: bindkey in tcsh

Post by Casper H.S. Dik - Network Security Engine » Sun, 15 Oct 2000 04:00:00


[[ PLEASE DON'T SEND ME EMAIL COPIES OF POSTINGS ]]


>Hello. Just a basic question about key bindings in tcsh.
>How could I bind "ctrl-right-arrow" to "forward-word" ?
>I know this is not very "vi-ish" nor "emacs-ish", but I'm quite used to
>such key-combo.
>I tried different syntaxes unsuccessully.

On many systems, ctl-right-arrow and right-arrow send the same
escape sequence.

You can check this with ^V<right-arrow> ^V<ctl-right-arrow>
both give ^[[C on this system.

Casper
--
Expressed in this posting are my opinions.  They are in no way related
to opinions held by my employer, Sun Microsystems.
Statements on Sun products included here are not gospel and may
be fiction rather than truth.

 
 
 

: bindkey in tcsh

Post by samuel kok » Sun, 15 Oct 2000 04:00:00


Thank you!!
I didn't know the "^V" sequence (quoted-insert, right?). I just tried on
my setup (linux *86, rxvt, tcsh) it gives me for "ctrl-right-arrow:
"^[Oc"

Thus the bindkeys
# ctrl-right-arrow for "forward word"
bindkey "^[Oc" forward-word
# ctrl-left-arrow for "back word"
bindkey "^[Od" backward-word

now works perfectly :))

Many thx :)

Sam.



> [[ PLEASE DON'T SEND ME EMAIL COPIES OF POSTINGS ]]


>>Hello. Just a basic question about key bindings in tcsh. How could I
>>bind "ctrl-right-arrow" to "forward-word" ?

>>I know this is not very "vi-ish" nor "emacs-ish", but I'm quite used to
>>such key-combo. I tried different syntaxes unsuccessully.

> On many systems, ctl-right-arrow and right-arrow send the same escape
> sequence.

> You can check this with ^V<right-arrow> ^V<ctl-right-arrow> both give
> ^[[C on this system.

> Casper
> --
> Expressed in this posting are my opinions.  They are in no way related
> to opinions held by my employer, Sun Microsystems. Statements on Sun
> products included here are not gospel and may be fiction rather than
> truth.