summaryrefslogtreecommitdiffstats
path: root/src/intrfn.c
diff options
context:
space:
mode:
authorChristophe Grenier <grenier@cgsecurity.org>2013-10-20 12:34:35 +0200
committerChristophe Grenier <grenier@cgsecurity.org>2013-10-20 12:34:35 +0200
commitba0f998648ec890d51febb4e51ad09737f5e38c6 (patch)
tree8e30da39f2726e7f45c73a2d31d18941ffdf9415 /src/intrfn.c
parent329eba4b044ea6e38306067e12be5e643ba07ef4 (diff)
Force white on black in (n)curses interface.
In some cases, the display was white on white.
Diffstat (limited to 'src/intrfn.c')
-rw-r--r--src/intrfn.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/intrfn.c b/src/intrfn.c
index e1f3535..0947b14 100644
--- a/src/intrfn.c
+++ b/src/intrfn.c
@@ -1133,19 +1133,22 @@ int start_ncurses(const char *prog_name, const char *real_prog_name)
free(terminfo);
}
#endif
- noecho();
-#ifndef DJGPP
- nonl(); /*don't use for Dos version but enter will work with it... dilema */
-#endif
- /* intrflush(stdscr, FALSE); */
- cbreak();
/* Should solve a problem with users who redefined the colors */
if(has_colors())
{
start_color();
+#ifdef HAVE_ASSUME_DEFAULT_COLORS
+ assume_default_colors(COLOR_WHITE,COLOR_BLACK);
+#endif
init_pair(1, COLOR_RED, COLOR_BLACK);
init_pair(2, COLOR_GREEN, COLOR_BLACK);
}
+ noecho();
+#ifndef DJGPP
+ nonl(); /*don't use for Dos version but enter will work with it... dilema */
+#endif
+ /* intrflush(stdscr, FALSE); */
+ cbreak();
curs_set(0);
{
int quit=0;