summaryrefslogtreecommitdiffstats
path: root/src/tui.c
diff options
context:
space:
mode:
authorAndrés <andmarti@gmail.com>2021-03-22 09:04:56 -0300
committerAndrés <andmarti@gmail.com>2021-03-22 09:04:56 -0300
commit34b4619e1c856dd4f48f9ea55cff603ca6d19a98 (patch)
tree4c4f3331860ff1d4a8da0fa6fbce3b846cde0cee /src/tui.c
parent97ef9034c09326f850f726785d91ea67ca4cfa86 (diff)
work on issue #482. added init_extended_pair according to NCURSES version macros..
Diffstat (limited to 'src/tui.c')
-rw-r--r--src/tui.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/tui.c b/src/tui.c
index ae9d9a9..c6aa73f 100644
--- a/src/tui.c
+++ b/src/tui.c
@@ -1480,7 +1480,11 @@ void ui_start_colors() {
* NOTE: calling init_pair with -1 sets it with default
* terminal foreground and background colors
*/
+#if defined(NCURSES_VERSION_MAJOR) && (( NCURSES_VERSION_MAJOR > 5 && defined(NCURSES_VERSION_MINOR) && NCURSES_VERSION_MINOR > 0) || NCURSES_VERSION_MAJOR > 6)
init_extended_pair( i*def+j+1, i-1, j-1); // i is fg and j is bg
+#else
+ init_pair(i*def+j+1, i-1, j-1); // i is fg and j is bg
+#endif
}
}
}