🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.emacs.bug
Article #99219

remapping ^H in gnu emacs

#99219
From: Martin Tomes
Date: Mon, 22 Oct 1990 08:02
51 lines
2226 bytes
The real answer is to remap your keyboard to generate DEL from the
backspace key.  This is particularly simple for users of X, but can
usually be done from terminals.

This is an extract from a program we use to set up UK keyboards.  I
only show the bit which sets up the delete keys.  This program runs on
Interactive UNIX, I have no idea if it works on Intel.

------------------------------------------------------------------------------
#include <stdio.h>
#include <sys/types.h>
#include <sys/at_ansi.h>
#include <sys/kd.h>

main ()

{

	struct kbentry keydef;

keydef.kb_table = 0x00;
keydef.kb_index = 0x4B;
keydef.kb_value = 


/* Make backspace delete. */
/* set Normal key stroke    */
keydef.kb_table = 0x00;  /* table 0x00 = normal key stroke */
keydef.kb_index = 14;    /* index = scan code */
keydef.kb_value = 0x7f;  /* value = hex valur of ascii char */
ioctl(0,KDSKBENT,& keydef);

/* set shifted key stroke   */
keydef.kb_table = 0x01;
keydef.kb_value = 0x7f;
ioctl(0,KDSKBENT,& keydef);

/* set altered key stroke   */
keydef.kb_table = 0x02;
keydef.kb_value = 0x7f;
ioctl(0,KDSKBENT,& keydef);

}
------------------------------------------------------------------------------

Martin Tomes

Janet:    mt00@uk.co.eurotherm    | Eurotherm Limited, Faraday Close,
Internet: mt00@eurotherm.co.uk    | Durrington, Worthing, W.Sussex, England.
UUCP:     {ukc,uunet}!etherm!mt00 | Phone: +44 903 68500  Fax: +44 903 65982
Technical Details
Message-ID: <7310.9010220802@jackdaw.eurotherm.co.uk>
Path: arc1-ca.pugleaf.net!gmdzi!unido!isaak!escher!nadia!smurf!ira.uka.de!sol.ctr.columbia.edu!zaphod.mps.ohio-state.edu!wuarchive!cs.utexas.edu!tut.cis.ohio-state.edu!eurotherm.co.uk!mt00
References: <112@frcs.UUCP>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: fb2f1,c853d05498ed3bf6,start
X-Google-Attributes: gidfb2f1,public
X-Google-ArrivalTime: 1990-10-22 01:02:15 PST
Path: arc1-ca.pugleaf.net!gmdzi!unido!isaak!escher!nadia!smurf!ira.uka.de!sol.ctr.columbia.edu!zaphod.mps.ohio-state.edu!wuarchive!cs.utexas.edu!tut.cis.ohio-state.edu!eurotherm.co.uk!mt00
From: mt00@eurotherm.co.uk (Martin Tomes)
Newsgroups: gnu.emacs.bug
Subject: remapping ^H in gnu emacs
Message-ID: <7310.9010220802@jackdaw.eurotherm.co.uk>
Date: 22 Oct 90 08:02:15 GMT
References: <112@frcs.UUCP>
Sender: daemon@tut.cis.ohio-state.edu
Distribution: gnu
Organization: GNUs Not Usenet
Lines: 51
Approved: bug-gnu-emacs@prep.ai.mit.edu
Posted: Mon Oct 22 09:02:15 1990