Remove TEXTCOLOR build option

This commit is contained in:
nhmall
2023-11-22 16:01:58 -05:00
parent 6272e18d7b
commit 04082a2033
60 changed files with 105 additions and 483 deletions

View File

@@ -932,7 +932,6 @@ struct amii_glyph_node {
static struct amii_glyph_node amii_g_nodes[NUMBER_GLYPH_NODES];
static char amii_glyph_buffer[GLYPH_BUFFER_SIZE];
#ifdef TEXTCOLOR
/*
* Map our amiga-specific colormap into the colormap specified in color.h.
* See winami.c for the amiga specific colormap.
@@ -963,7 +962,6 @@ int backg[AMII_MAXCOLORS] = {
#define CLR_WHITE 15
#define CLR_MAX 16
#endif
#endif
#ifndef TESTING
/*
@@ -1062,13 +1060,8 @@ int color_index, glyph;
curx = cw->curx;
cury = cw->cury;
#ifdef TEXTCOLOR
fg_color = foreg[color_index];
bg_color = backg[color_index];
#else
fg_color = 1;
bg_color = 0;
#endif /* TEXTCOLOR */
/* See if we have enough character buffer space... */
if (glyph_buffer_index >= GLYPH_BUFFER_SIZE)

View File

@@ -68,11 +68,7 @@ int dir;
return;
if (!WINVERS_AMIV) {
#ifdef TEXTCOLOR
amii_numcolors = 8;
#else
amii_numcolors = 4;
#endif
amii_defpens[0] = C_BLACK; /* DETAILPEN */
amii_defpens[1] = C_BLUE; /* BLOCKPEN */
amii_defpens[2] = C_BROWN; /* TEXTPEN */
@@ -1225,11 +1221,7 @@ char **argv;
/* While openscreen fails try fewer colors to see if that is the problem.
*/
while ((HackScreen = OpenScreen((void *) &NewHackScreen)) == NULL) {
#ifdef TEXTCOLOR
if (--NewHackScreen.Depth < 3)
#else
if (--NewHackScreen.Depth < 2)
#endif
Abort(AN_OpenScreen & ~AT_DeadEnd);
}
amii_numcolors = 1L << NewHackScreen.Depth;
@@ -2017,15 +2009,11 @@ if(u.uz.dlevel != x){
/* Move the cursor. */
amii_curs(win, x, y + 2);
#ifdef TEXTCOLOR
/* Turn off color if rogue level. */
if (Is_rogue_level(&u.uz))
color = NO_COLOR;
amiga_print_glyph(win, color, ch);
#else
g_putch(ch); /* print the character */
#endif
cw->curx++; /* one character over */
}
}

View File

@@ -28,9 +28,7 @@ static char DOSgetch(void);
static char BIOSgetch(void);
static void init_aline(void);
char *_a_line; /* for Line A variables */
#ifdef TEXTCOLOR
boolean colors_changed = FALSE;
#endif
int
tgetch()
@@ -312,7 +310,6 @@ init_aline()
#endif
}
#ifdef TEXTCOLOR
/* used in termcap.c to decide how to set up the hilites */
unsigned long tos_numcolors = 2;
@@ -343,7 +340,6 @@ restore_colors()
nh_HE = plainHE;
colors_changed = FALSE;
}
#endif /* TEXTCOLOR */
#ifdef SUSPEND

View File

@@ -861,8 +861,6 @@ void
nhglyph2charcolor(short g, uchar *ch, int *color)
{
int offset;
#ifdef TEXTCOLOR
#define zap_color(n) *color = iflags.use_color ? zapcolors[n] : NO_COLOR
#define cmap_color(n) *color = iflags.use_color ? defsyms[n].color : NO_COLOR
#define obj_color(n) \
@@ -872,17 +870,6 @@ nhglyph2charcolor(short g, uchar *ch, int *color)
#define warn_color(n) \
*color = iflags.use_color ? def_warnsyms[n].color : NO_COLOR
#else /* no text color */
#define zap_color(n)
#define cmap_color(n)
#define obj_color(n)
#define mon_color(n)
#define pet_color(c)
#define warn_color(c)
*color = CLR_WHITE;
#endif
if ((offset = (g - GLYPH_WARNING_OFF)) >= 0) { /* a warning flash */
*ch = showsyms[offset + SYM_OFF_W];
warn_color(offset);