X-Git-Url: https://www.fleuret.org/cgi-bin/gitweb/gitweb.cgi?a=blobdiff_plain;ds=sidebyside;f=selector.cc;h=8aeabca371ccaac25bf37cba1c3e76639c5ff211;hb=270045d0c175f8c2edabf63a2c1ff9f80bfa4352;hp=f740e899ceb216568d5c88930aa1be8864fe822f;hpb=5b4e65213ae6101671e4eb06788b152b34b34d15;p=selector.git diff --git a/selector.cc b/selector.cc index f740e89..8aeabca 100644 --- a/selector.cc +++ b/selector.cc @@ -60,10 +60,6 @@ int case_sensitive = 0; char *title = 0; int error_flash = 0; -#define COLOR_MODELINE 1 -#define COLOR_FOCUS_LINE 2 -#define COLOR_ERROR 3 - int attr_modeline, attr_focus_line, attr_error; ////////////////////////////////////////////////////////////////////// @@ -915,13 +911,14 @@ int main(int argc, char **argv) { exit(1); } - init_pair(COLOR_MODELINE, color_fg_modeline, color_bg_modeline); - init_pair(COLOR_FOCUS_LINE, color_fg_highlight, color_bg_highlight); - init_pair(COLOR_ERROR, COLOR_WHITE, COLOR_RED); + init_pair(1, color_fg_modeline, color_bg_modeline); + attr_modeline = COLOR_PAIR(1); + + init_pair(2, color_fg_highlight, color_bg_highlight); + attr_focus_line = COLOR_PAIR(2); - attr_modeline = COLOR_PAIR(COLOR_MODELINE); - attr_focus_line = COLOR_PAIR(COLOR_FOCUS_LINE); - attr_error = COLOR_PAIR(COLOR_ERROR); + init_pair(3, COLOR_WHITE, COLOR_RED); + attr_error = COLOR_PAIR(3); }