barry@aurora.UUCP (Kenn Barry) (07/03/87)
[]
I just recently installed MicroEMACS 3.8i as my Amiga system
editor, and though the code was already #ifdef'ed for the Amiga, I ran
into a couple of needed alterations for it, so I thought I'd post them.
The first is a problem that's come up with nearly every release
of uemacs for those of us using Manx. The Manx default is to have the
ctrl-C interrupt enabled, and since ctrl-C is a uemacs command, there's
a conflict. Hitting ctrl-C will bomb uemacs, though not immediately; it
happens on the next disk access, when the system calls Check_Abort(), and
realizes ctrl-C was hit.
Anyway, the fix is to add the following lines to the termio.c
module:
-------------------------------------------------------------------------
In the ttopen() routine, here's the original code:
#if AMIGA
terminal = Open("RAW:1/1/639/199/MicroEMACS 3.7/Amiga", NEW);
#endif
Change it to the following:
#if AMIGA
extern Enable_Abort; /* Turn off ctrl-C interrupt */
Enable_Abort = 0; /* for the Manx compiler */
terminal = Open("RAW:1/1/639/199/MicroEMACS 3.7/Amiga", NEW);
#endif
Now change the ttclose() routine from this:
#if AMIGA
amg_flush();
Close(terminal);
#endif
to this:
#if AMIGA
amg_flush();
Enable_Abort = 1; /* Fix for Manx */
Close(terminal);
#endif
------------------------------------------------------------------------
The other fix is minor, but worth mentioning: if you turn on the
color option, you'll get peculiar results. It was written for MSDOS
machines, and the color codes are different. For instance, what's
"white" to a PC is "orange" (using the standard workbench color
selections) on an Amiga. Result: all your text will be in orange if you
turn this option on. And the add-mode commands to change colors will
have the wrong names attached to the colors - confusing!
The fix goes in the edef.h header file. Make the following
changes:
-------------------------------------------------------------------------
Change this:
char *cname[] = { /* names of colors */
"BLACK", "RED", "GREEN", "YELLOW", "BLUE",
"MAGENTA", "CYAN", "WHITE"};
to this:
#if AMIGA
char *cname[] = { /* names of colors */
"BLUE", "WHITE", "BLACK", "ORANGE", "BLUE",
"WHITE", "BLACK", "ORANGE"};
#else
char *cname[] = { /* names of colors */
"BLACK", "RED", "GREEN", "YELLOW", "BLUE",
"MAGENTA", "CYAN", "WHITE"};
#endif
And then change this:
int gfcolor = 7; /* global forgrnd color (white) */
to this:
#if AMIGA
int gfcolor = 1; /* global forgrnd color (white) */
#else
int gfcolor = 7; /* global forgrnd color (white) */
#endif
-------------------------------------------------------------------------
One final note: you'll need to compile with the long integer
option (+L). Without it, you'll get an error-free compile and link, but
the sucker won't run. If anybody has a fix for *that*, please let me
know. I'm short of space on my system disk, and I'd love to be able to
compile uemacs into a more compact executable.
- From the Crow's Nest - Kenn Barry
NASA-Ames Research Center
Moffett Field, CA
-----------------------------------------------------------------------------
ELECTRIC AVENUE: {hplabs,seismo,dual,ihnp4}!ames!aurora!barryphillip@cbmvax.UUCP (Phillip Lindsay GUEST) (07/08/87)
in article <752@aurora.UUCP>, barry@aurora.UUCP (Kenn Barry) says: > Keywords: minor patches > > [] > I just recently installed MicroEMACS 3.8i as my Amiga system > editor, and though the code was already #ifdef'ed for the Amiga, I ran > into a couple of needed alterations for it, so I thought I'd post them. I rewrote the termio code so me3.8.i opened in a single bitplane screen like Andy's MicroEMACS...it will default to the workbench screen modes/size etc... If anyone is interested I can email the change or post. ( the screen throughput is much better ) -phil ============================================================================== Phillip (Flip) Lindsay - Wake up and watch CNN at: Heather Ridge Apts. #G-115 UUCP: {ihnp4|seismo|caip}!cbmvax!phillip Mantua, NJ 08051 No warranty is implied or otherwise given in the form of suggestion or example. Any opinions found here are of my making.