follow-up to curses windowcolors
Make sure the windowcolors option can be specified more than once without a config file warning. Make the struct holding the details a little more extendable.
This commit is contained in:
@@ -195,6 +195,16 @@ struct debug_flags {
|
||||
#endif
|
||||
};
|
||||
|
||||
enum windowcolors_windows {
|
||||
wcolor_menu, wcolor_message, wcolor_status, wcolor_text,
|
||||
WC_COUNT
|
||||
};
|
||||
|
||||
struct windowcolors_struct {
|
||||
char *fg;
|
||||
char *bg;
|
||||
};
|
||||
|
||||
struct accessibility_data {
|
||||
boolean accessiblemsg; /* use msg_loc for plined messages */
|
||||
coord msg_loc; /* accessiblemsg: location */
|
||||
@@ -379,6 +389,7 @@ struct instance_flags {
|
||||
int wc_align_status; /* status win at top|bot|right|left */
|
||||
int wc_align_message; /* message win at top|bot|right|left */
|
||||
int wc_vary_msgcount; /* show more old messages at a time */
|
||||
#if 0
|
||||
char *wc_foregrnd_menu; /* points to foregrnd color name for menu win */
|
||||
char *wc_backgrnd_menu; /* points to backgrnd color name for menu win */
|
||||
char *wc_foregrnd_message; /* points to foregrnd color name for msg win */
|
||||
@@ -387,6 +398,9 @@ struct instance_flags {
|
||||
char *wc_backgrnd_status; /* points to backgrnd color name for status */
|
||||
char *wc_foregrnd_text; /* points to foregrnd color name for text win */
|
||||
char *wc_backgrnd_text; /* points to backgrnd color name for text win */
|
||||
#else
|
||||
struct windowcolors_struct wcolors[WC_COUNT];
|
||||
#endif
|
||||
char *wc_font_map; /* points to font name for the map win */
|
||||
char *wc_font_message; /* points to font name for message win */
|
||||
char *wc_font_status; /* points to font name for status win */
|
||||
|
||||
@@ -96,10 +96,12 @@ static int optfn_##a(int, int, boolean, char *, char *);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/* B:nm, ln, opt_*, setwhere?, on?, negat?, val?, dup?, hndlr? Alias, bool_p, term */
|
||||
/* C:nm, ln, opt_*, setwhere?, negateok?, valok?, dupok?, hndlr? Alias, desc */
|
||||
/* P:pfx, ln, opt_*, setwhere?, negateok?, valok?, dupok?, hndlr? Alias, desc*/
|
||||
|
||||
/* B:nm, sec, ln, opt_*, setwhere?, on?, negat?, val?, dup?, hndlr? Alias,
|
||||
bool_p, term */
|
||||
/* C:nm, sec, ln, opt_*, setwhere?, negateok?, valok?, dupok?, hndlr? Alias,
|
||||
desc */
|
||||
/* P:pfx, sec, ln, opt_*, setwhere?, negateok?, valok?, dupok?, hndlr? Alias,
|
||||
desc*/
|
||||
/*
|
||||
* Most of the options are in alphabetical order; a few are forced
|
||||
* to the top of list so that doset() will list them first and
|
||||
@@ -850,7 +852,7 @@ static int optfn_##a(int, int, boolean, char *, char *);
|
||||
No, Yes, No, No, NoAlias, "window processor to use")
|
||||
#endif
|
||||
NHOPTC(windowcolors, Advanced, 80, opt_in, set_gameview,
|
||||
No, Yes, No, No, NoAlias,
|
||||
No, Yes, Yes, No, NoAlias,
|
||||
"the foreground/background colors of windows")
|
||||
/* NHOPTC(windowtype) -- moved to top */
|
||||
NHOPTB(wizmgender, Advanced, 0, opt_in, set_wizonly,
|
||||
|
||||
Reference in New Issue
Block a user