delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2003/02/18/20:09:11

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-Id: <5.2.0.9.0.20030218185859.103df640@rogue.codemeta.com>
X-Sender: lee AT rogue DOT codemeta DOT com (Unverified)
Date: Tue, 18 Feb 2003 20:05:04 -0500
To: cygwin AT cygwin DOT com
From: "Lee D. Rothstein" <lee AT veritech DOT com>
Subject: .inputrc and command line edit mode function key remapping
Mime-Version: 1.0

Think of this as a brief FUQ (a veritable 'Quickie', as
it were) -- Frequently Unanswered Questions

Disclaimer/Alibi
----------------
These are really questions for the 'bash' group, except
that they specifically deal with the PC and its
keyboard (*and* I'm using 'bash' on Cygwin).

I've searched for answers throughout the Cygwin,
'emacs' and 'bash' documentation, and the Web and even
bought the book, /Learning the bash shell/. Alas, no
FUQing help! ;-)

I plan to document this in some copylefted docs, so you
should be able to leverage the time of your answers.

Q1 -- When you remap a 'bash' Edit Mode function in
.inputrc, it looks like this:

"\e[3~":      delete-char # DEL key

The entity in double quotes ("\e[3~"), I'm calling the
"key ID (KID)". In the above '.inputrc' declaration,
the function 'delete-char' being remapped from its
default key assignment to the KID -- "\e[3~" -- the
<DEL> key.

What are the KIDs of the following IBM PC keys
(specified below with facsimiles of the key caps
contained in angle brackets -- '<...>')?

Cursor control key pad
----------------------
<HOME>
<END>
<left-arrow>
<right-arrow>
<PAGE_UP>
<PAGE_DOWN>
<INSERT>

Numeric pad
-----------
<->
<+>
<ENTER>
</>

In general, I'd like a table that maps the KIDs for all
104 keys on the keyboard I use. Or, better still, is
there a way to use scan codes?

(Incidentally, what makes finding a table of these
KIDs so difficult is the failure of the documentation
to assign this concept a unique, or even a consistent
word.)

Q2
--

Is there a way to make the <INSERT> key a toggle
between the insert and overwrite modes of 'bash'
edit mode?

I used to have these figured out for 'Microemacs', but
that was half a lifetime ago, for me, and Microemacs
supported scan codes, if I remember correctly.

The discerning reader will have surmised both from
these questions and my earlier query 'on the humble
<DEL> key', that I am trying to make a PC, under the
estimable Cygwin, exploit those few niceties of the PC
(keyboard).

Thanks

Lee

P.S. In anticipation of the "righteous" among you being
      offended by the term 'FUQ', I shared your
      indignation; it occurred shortly after buying the
      ill-fated -- and referenced -- 'bash' book. (Yes,
      it's true; I'm bashing the 'bash' book.)

      And, please, whatever you do, don't kid a KIDer. ;-)


Lee D. Rothstein -- lee AT veritech DOT com
VeriTech -- 603-424-2900
7 Merry Meeting Drive
Merrimack, NH 03054-2934

----------






--
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/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019