Color initialization trimming for X
Этот коммит содержится в:
родитель
ee2d2c2f1b
Коммит
b7eab92d34
@ -1,3 +1,8 @@
|
||||
1998-05-15 Miguel de Icaza <miguel@nuclecu.unam.mx>
|
||||
|
||||
* color.c (init_colors): Provide X-only version of color
|
||||
initialization.
|
||||
|
||||
Thu May 14 01:56:11 1998 Norbert Warmuth <k3190@fh-sw.de>
|
||||
|
||||
* configure.in: Don't add -lintl to LIBS when included gettext is
|
||||
|
30
src/color.c
30
src/color.c
@ -234,6 +234,29 @@ static void configure_colors (void)
|
||||
int attr_pairs [MAX_PAIRS];
|
||||
#endif
|
||||
|
||||
static void
|
||||
load_dialog_colors (void)
|
||||
{
|
||||
dialog_colors [0] = COLOR_NORMAL;
|
||||
dialog_colors [1] = COLOR_FOCUS;
|
||||
dialog_colors [2] = COLOR_HOT_NORMAL;
|
||||
dialog_colors [3] = COLOR_HOT_FOCUS;
|
||||
}
|
||||
|
||||
#ifdef HAVE_X
|
||||
void
|
||||
init_colors (void)
|
||||
{
|
||||
int i;
|
||||
|
||||
use_colors = 1;
|
||||
start_color ();
|
||||
configure_colors ();
|
||||
for (i = 0; i < ELEMENTS (color_map); i++)
|
||||
init_pair (i+1, color_map_fg(i), color_map_bg(i));
|
||||
load_dialog_colors ();
|
||||
}
|
||||
#else
|
||||
void init_colors (void)
|
||||
{
|
||||
int i;
|
||||
@ -283,12 +306,9 @@ void init_colors (void)
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
dialog_colors [0] = COLOR_NORMAL;
|
||||
dialog_colors [1] = COLOR_FOCUS;
|
||||
dialog_colors [2] = COLOR_HOT_NORMAL;
|
||||
dialog_colors [3] = COLOR_HOT_FOCUS;
|
||||
load_dialog_colors ();
|
||||
}
|
||||
#endif
|
||||
|
||||
void toggle_color_mode (void)
|
||||
{
|
||||
|
Загрузка…
Ссылка в новой задаче
Block a user