Mercurial > pidgin.yaz
diff console/libgnt/gntcolors.c @ 14299:ea5193c23171
[gaim-migrate @ 16989]
Now the customcolors should work. Apparently I didn't include it in last commit.
committer: Tailor Script <tailor@pidgin.im>
author | Sadrul Habib Chowdhury <imadil@gmail.com> |
---|---|
date | Wed, 23 Aug 2006 01:35:44 +0000 |
parents | e7de1f6d9f35 |
children | 9df5dd999402 |
line wrap: on
line diff
--- a/console/libgnt/gntcolors.c Wed Aug 23 01:09:33 2006 +0000 +++ b/console/libgnt/gntcolors.c Wed Aug 23 01:35:44 2006 +0000 @@ -1,5 +1,6 @@ #include <ncursesw/ncurses.h> #include "gntcolors.h" +#include "gntstyle.h" #include <glib.h> @@ -36,7 +37,7 @@ void gnt_init_colors() { start_color(); - if (can_change_color()) + if (gnt_style_get_bool(GNT_STYLE_COLOR, FALSE) && can_change_color()) { backup_colors(); @@ -63,6 +64,7 @@ } else { + use_default_colors(); init_pair(GNT_COLOR_NORMAL, COLOR_BLACK, COLOR_WHITE); init_pair(GNT_COLOR_HIGHLIGHT, COLOR_WHITE, COLOR_BLUE); init_pair(GNT_COLOR_SHADOW, COLOR_BLACK, COLOR_BLACK); @@ -77,7 +79,8 @@ void gnt_uninit_colors() { - restore_colors(); + if (gnt_style_get_bool(GNT_STYLE_COLOR, FALSE) && can_change_color()) + restore_colors(); } static int