From 723e17b6eeb2a423cc69c774fd9d22b94dc65b04 Mon Sep 17 00:00:00 2001 From: "nethack.allison" Date: Sat, 16 Mar 2002 18:54:16 +0000 Subject: [PATCH] (from Yitzhak) This is the part of Yitzhak's patch not currently under discussion. --- src/options.c | 4 ++-- sys/winnt/defaults.nh | 15 ++++++++++++--- win/win32/mhmain.c | 4 ++-- win/win32/mswproc.c | 25 ++++++++++++++++--------- 4 files changed, 32 insertions(+), 16 deletions(-) diff --git a/src/options.c b/src/options.c index 00662750c..009f04d0a 100644 --- a/src/options.c +++ b/src/options.c @@ -1782,7 +1782,7 @@ goodfruit: /* WINCAP * map_mode:[tiles|ascii4x6|ascii6x8|ascii8x8|ascii16x8|ascii7x12|ascii8x12| - ascii15x12|ascii12x16|ascii10x18|fit_to_screen] */ + ascii16x12|ascii12x16|ascii10x18|fit_to_screen] */ fullname = "map_mode"; if (match_optname(opts, fullname, sizeof("map_mode")-1, TRUE)) { op = string_for_opt(opts, negated); @@ -1801,7 +1801,7 @@ goodfruit: iflags.wc_map_mode = MAP_MODE_ASCII7x12; else if (!strncmpi (op, "ascii8x12", sizeof("ascii8x12")-1)) iflags.wc_map_mode = MAP_MODE_ASCII8x12; - else if (!strncmpi (op, "ascii15x12", sizeof("ascii15x12")-1)) + else if (!strncmpi (op, "ascii16x12", sizeof("ascii16x12")-1)) iflags.wc_map_mode = MAP_MODE_ASCII16x12; else if (!strncmpi (op, "ascii12x16", sizeof("ascii12x16")-1)) iflags.wc_map_mode = MAP_MODE_ASCII12x16; diff --git a/sys/winnt/defaults.nh b/sys/winnt/defaults.nh index 954d30296..598258eaf 100644 --- a/sys/winnt/defaults.nh +++ b/sys/winnt/defaults.nh @@ -58,11 +58,20 @@ OPTIONS=font_text:Courier New,font_size_text:9 OPTIONS=font_status:Courier New,font_size_status:10 # Other -OPTIONS=hilite_pet +OPTIONS=hilite_pet,!toptenwin #OPTIONS=!splash_screen,player_selection:prompts -# Top Ten Window. Highly Recommended. -#OPTIONS=toptenwin +# Status/message window colors +# Possible color options include: +# six digit hexadecimal RGB color value ("#8F8F8F"), black, red, green, brown, +# blue, magenta, cyan, gray (or grey), orange, brightgreen, yellow, brightblue, +# brightmagenta, brightcyan, white, trueblack, purple, silver, maroon, fuchsia, +# lime, olive, navy, teal, aqua, activeborder, activecaption, appworkspace, +# background, btnface, btnshadow, btntext, captiontext, graytext, highlight, +# highlighttext, inactiveborder, inactivecaption, menu, menutext, scrollbar, +# window, windowframe, windowtext. + +OPTIONS=windowcolors:status windowtext/window message windowtext/window # #HACKDIR=c:\games\nethack diff --git a/win/win32/mhmain.c b/win/win32/mhmain.c index e77b37a90..71c5ff824 100644 --- a/win/win32/mhmain.c +++ b/win/win32/mhmain.c @@ -888,8 +888,8 @@ static struct t_menu2mapmode { { IDM_MAP_ASCII16X8, MAP_MODE_ASCII16x8 }, { IDM_MAP_ASCII7X12, MAP_MODE_ASCII7x12 }, { IDM_MAP_ASCII8X12, MAP_MODE_ASCII8x12 }, - { IDM_MAP_ASCII12X16, MAP_MODE_ASCII16x12 }, - { IDM_MAP_ASCII16X12, MAP_MODE_ASCII12x16 }, + { IDM_MAP_ASCII12X16, MAP_MODE_ASCII12x16 }, + { IDM_MAP_ASCII16X12, MAP_MODE_ASCII16x12 }, { IDM_MAP_ASCII10X18, MAP_MODE_ASCII10x18 }, { IDM_MAP_FIT_TO_SCREEN, MAP_MODE_ASCII_FIT_TO_SCREEN }, { -1, -1 } diff --git a/win/win32/mswproc.c b/win/win32/mswproc.c index 97b8267fe..53841688b 100644 --- a/win/win32/mswproc.c +++ b/win/win32/mswproc.c @@ -185,6 +185,13 @@ void mswin_init_nhwindows(int* argc, char** argv) /* force tabs in menus */ iflags.menu_tab_sep = 1; + /* force toptenwin to be true. toptenwin is the option that decides whether to + * write output to a window or stdout. stdout doesn't make sense on Windows + * non-console applications + */ + flags.toptenwin = 1; + set_option_mod_status("toptenwin", SET_IN_FILE); + /* initialize map tiles bitmap */ initMapTiles(); @@ -1943,24 +1950,24 @@ typedef struct ctbv static color_table_brush_value color_table_brush[] = { { "activeborder", COLOR_ACTIVEBORDER }, { "activecaption", COLOR_ACTIVECAPTION }, - { "appworkspace", COLOR_APPWORKSPACE }, - { "background", COLOR_BACKGROUND }, + { "appworkspace", COLOR_APPWORKSPACE }, + { "background", COLOR_BACKGROUND }, { "btnface", COLOR_BTNFACE }, { "btnshadow", COLOR_BTNSHADOW }, { "btntext", COLOR_BTNTEXT }, - { "captiontext", COLOR_CAPTIONTEXT }, + { "captiontext", COLOR_CAPTIONTEXT }, { "graytext", COLOR_GRAYTEXT }, { "greytext", COLOR_GRAYTEXT }, - { "highlight", COLOR_HIGHLIGHT }, + { "highlight", COLOR_HIGHLIGHT }, { "highlighttext", COLOR_HIGHLIGHTTEXT }, { "inactiveborder", COLOR_INACTIVEBORDER }, { "inactivecaption", COLOR_INACTIVECAPTION }, - { "menu", COLOR_MENU }, + { "menu", COLOR_MENU }, { "menutext", COLOR_MENUTEXT }, - { "scrollbar", COLOR_SCROLLBAR }, - { "window", COLOR_WINDOW }, - { "windowframe", COLOR_WINDOWFRAME }, - { "windowtext", COLOR_WINDOWTEXT }, + { "scrollbar", COLOR_SCROLLBAR }, + { "window", COLOR_WINDOW }, + { "windowframe", COLOR_WINDOWFRAME }, + { "windowtext", COLOR_WINDOWTEXT }, { "", -1 }, };