diff --git a/include/wintty.h b/include/wintty.h index 26add9a5f..4fc07fe2d 100644 --- a/include/wintty.h +++ b/include/wintty.h @@ -21,7 +21,7 @@ struct tty_perminvent_cell { Bitfield(text, 1); Bitfield(glyph, 1); union ttycellcontent content; - int32_t color; /* adjusted color 0 = ignore + uint32 color; /* adjusted color 0 = ignore * 1-16 = NetHack color + 1 * 17..16,777,233 = 24-bit color + 17 */ diff --git a/src/decl.c b/src/decl.c index da1fdf3be..0bef158d7 100644 --- a/src/decl.c +++ b/src/decl.c @@ -756,7 +756,7 @@ static const struct instance_globals_s g_init_s = { { 0, 0 }, /* save_dlevel */ /* symbols.c */ { DUMMY }, /* symset */ - { { 0 }, { 0 } }, /* symset_customizations */ + { { { 0 } }, { { 0 } } }, /* symset_customizations */ DUMMY, /* showsyms */ /* files.c */ 0, /* symset_count */ diff --git a/win/tty/wintty.c b/win/tty/wintty.c index 16bb94492..97d3cf575 100644 --- a/win/tty/wintty.c +++ b/win/tty/wintty.c @@ -287,7 +287,7 @@ static void tty_invent_box_glyph_init(struct WinDesc *cw); static boolean assesstty(enum inv_modes, short *, short *, long *, long *, long *, long *, long *); static void ttyinv_populate_slot(struct WinDesc *, int, int, - const char *, int32_t, int); + const char *, uint32, int); #endif /* TTY_PERM_INVENT */ /* @@ -3067,7 +3067,8 @@ ttyinv_add_menu( row = (slot % rows_per_side) + 1; /* +1: top border */ /* side: left side panel or right side panel, not a window column */ side = slot / rows_per_side; - ttyinv_populate_slot(cw, row, side, text, clr, startcolor_at); + ttyinv_populate_slot(cw, row, side, text, + (uint32) clr, startcolor_at); } return; } @@ -3220,8 +3221,8 @@ ttyinv_end_menu(int window, struct WinDesc *cw) static void ttyinv_render(winid window, struct WinDesc *cw) { - int row, col, slot, side, filled_count = 0, slot_limit, - current_row_color = NO_COLOR; + int row, col, slot, side, filled_count = 0, slot_limit; + uint32 current_row_color = NO_COLOR; struct tty_perminvent_cell *cell; char invbuf[BUFSZ]; boolean force_redraw = gp.program_state.in_docrt ? TRUE : FALSE, @@ -3335,7 +3336,7 @@ ttyinv_populate_slot( int row, /* 'row' within the window, not within screen */ int side, /* 'side'==0 is left panel or ==1 is right panel */ const char *text, - int32_t color, + uint32 color, int clroffset) { struct tty_perminvent_cell *cell;