Bug 143040 - /etc/inputrc keysequence bad for CTRL-left / CTRL-right in xterm
/etc/inputrc keysequence bad for CTRL-left / CTRL-right in xterm
Status: CLOSED DUPLICATE of bug 80860
Product: Fedora
Classification: Fedora
Component: setup (Show other bugs)
2
All Linux
medium Severity low
: ---
: ---
Assigned To: Bill Nottingham
David Lawrence
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2004-12-15 16:43 EST by Richard Andrews
Modified: 2014-03-16 22:51 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-02-21 14:07:43 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Richard Andrews 2004-12-15 16:43:42 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.5)
Gecko/20041107 Firefox/1.0

Description of problem:
/etc/inputrc attempts to set up CTRL-left and CRTL-right (cursor arrow
keys) to backward-word  and forward-word respectively. However I find
that they do not work correctly in xterm.

In gnome-terminal the key combination works, but in xterm it results
in "5D" being written at current curson position.

Note: as a work-around the emacs Alt-f and Alt-b combinations do work
in both cases.


Version-Release number of selected component (if applicable):
2.05b-38

How reproducible:
Always

Steps to Reproduce:
1. start xterm with bash as shell
2. type command
3. CTRL-left 



Actual Results:  prints "5D"

Expected Results:  cursor should have moved backward by a word

Additional info:

This can be fixed for xterm by modifying /etc/inputrc as follows

Change these lines

"\e[5C": forward-word
"\e[5D": backward-word

to

"\e[1;5C": forward-word
"\e[1;5D": backward-word
Comment 1 Richard Andrews 2004-12-15 21:17:52 EST
Just discovered that the above fix breaks bash in gnome-terminal.

I guess the real fix lies somewhere in standardising the behaviour of
xterm and gnome-terminal, but I'm not an expert and don't know which
one is misbehaving.

Is it possible to have conditional inputrc sections? Eg.
gnome-terminal identifies itself by setting COLORTERM=gnome-terminal,
while xterm does not.
Comment 2 Bill Nottingham 2004-12-16 09:44:41 EST
This should work in FC3.

*** This bug has been marked as a duplicate of 80860 ***
Comment 3 Red Hat Bugzilla 2006-02-21 14:07:43 EST
Changed to 'CLOSED' state since 'RESOLVED' has been deprecated.

Note You need to log in before you can comment on or make changes to this bug.