Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!cmcl2!phri!dasys1!manes From: manes@dasys1.UUCP (Steve Manes) Newsgroups: comp.unix.xenix,comp.emacs Subject: Re: Hack for MicroEMACS to support fkeys/keypad under Message-ID: <2119@dasys1.UUCP> Date: Tue, 1-Dec-87 13:07:01 EST Article-I.D.: dasys1.2119 Posted: Tue Dec 1 13:07:01 1987 Date-Received: Sat, 5-Dec-87 04:24:45 EST References: <1132@sugar.UUCP> Reply-To: manes@dasys1.UUCP (Steve Manes) Organization: Datamerica Systems, NYC Lines: 54 Keywords: Microport MicroEMACS function keys hack Xref: mnetor comp.unix.xenix:1247 comp.emacs:2478 In article <1132@sugar.UUCP> karl@sugar.UUCP (Karl Lehenbauer) writes: >This is a context diff of a hack to make MicroEMACS function keys work under >Microport Unix System V/286. You also have to replace your ANSI keyboard >mappings, defined in '/etc/rc.d/keybrd.rc' with one I've included as a >shell archive at the end. Yes, it's gross, but it makes the function, >arrow keys, and miscellaneous keypad keys work. Consult keybrd.rc >for their definitions. It's not necessary to add a new protocol code character to make uEMACS work with Microport UNIX. I modified Daniel's code to allow it to use Microport's standard ANSI escape codes as follows. This is the beginning of his function 'get1key' in file 'input.c': get1key() int c; #if AMIGA int d; #endif #if UPORT static int gotmeta; #endif /* get a keystroke */ c = tgetc(); #ifdef UPORT if (gotmeta && c == '[' || c == 'O')) { gotmeta = FALSE; return( (c == '[') ? (SPEC | tgetc()) : (META | SPEC | tgetc()) ); } gotmeta = (c == 0x1b) ? TRUE : FALSE; #endif and in the function 'getcmd': ... ... /* process META prefix */ if (c == metac) { c = get1key(); #ifdef UPORT if (c & SPEC) return(c); #endif ... ... This allows Microport function keys to be attached to M-FNx keys. You'll also need to do the 'bind.c' patch mentioned earlier in the discussion to enable both upper and lowercase function key codes. -- +----------------------------------------------------------------------- + Steve Manes Roxy Recorders, Inc. NYC + decvax!philabs!cmcl2!hombre!magpie!manes Magpie BBS: 212-420-0527 + uunet!iuvax!bsu-cs!zoo-hq!magpie!manes 300/1200/2400