Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions src/options.c
Original file line number Diff line number Diff line change
Expand Up @@ -7728,13 +7728,19 @@ boolean
get_menu_coloring(const char *str, int *color, int *attr)
{
struct menucoloring *tmpmc;
boolean first_match = TRUE;

if (iflags.use_menu_color)
for (tmpmc = gm.menu_colorings; tmpmc; tmpmc = tmpmc->next)
if (regex_match(str, tmpmc->match)) {
*color = tmpmc->color;
if (first_match) {
*color = tmpmc->color;
first_match = FALSE;
}
*attr = tmpmc->attr;
return TRUE;
if (*attr != ATR_NONE) {
return TRUE;
}
}
return FALSE;
}
Expand Down