--windowtype:foo on command line

There's no need to process windowtype a second time after options
parsing.  The sequence set windowtype, process options, set
windowtype again was intended to deal with the options setting it
to some other value, but there's a flag available to disable that
from happening.
This commit is contained in:
PatR
2023-12-01 22:58:53 -08:00
parent 9d910773d0
commit a0008f7376
2 changed files with 21 additions and 24 deletions

View File

@@ -1,4 +1,4 @@
/* NetHack 3.7 mdlib.c $NHDT-Date: 1655402414 2022/06/16 18:00:14 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.31 $ */
/* NetHack 3.7 mdlib.c $NHDT-Date: 1701499945 2023/12/02 06:52:25 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.51 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Kenneth Lorber, Kensington, Maryland, 2015. */
/* Copyright (c) M. Stephenson, 1990, 1991. */
@@ -100,7 +100,7 @@ static struct version_info version;
static const char opt_indent[] = " ";
struct win_information {
const char *id, /* DEFAULT_WINDOW_SYS string */
const char *id, /* windowtype value */
*name; /* description, often same as id */
boolean valid;
};
@@ -108,7 +108,7 @@ struct win_information {
static struct win_information window_opts[] = {
#ifdef TTY_GRAPHICS
{ "tty",
/* testing 'TILES_IN_GLYPHMAP' here would bring confusion because it could
/* testing TILES_IN_GLYPHMAP here would bring confusion because it could
apply to another interface such as X11, so check MSDOS explicitly
instead; even checking TTY_TILES_ESCCODES would probably be
confusing to most users (and it will already be listed separately