diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2021-12-25 14:59:18 -0800 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2021-12-25 14:59:18 -0800 |
commit | 526d37e4ac1529685eb5378368cc7a028eb6b330 (patch) | |
tree | e672009ead4456ac009884bb2fdda1e750f56227 | |
parent | ee66da41f53e1d23ff83cbca93fc10e8eee34945 (diff) | |
download | teliva-526d37e4ac1529685eb5378368cc7a028eb6b330.tar.gz |
fix menu colors in all color schemes
It looks like attron doesn't actually enable colors near 256, even though https://linux.die.net/man/3/attron suggests it does. > COLOR_PAIR values can only be OR'd with attributes if the pair > number is less than 256.
-rw-r--r-- | src/teliva.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/teliva.c b/src/teliva.c index 9a6ec3e..c195211 100644 --- a/src/teliva.c +++ b/src/teliva.c @@ -32,7 +32,8 @@ void draw_menu_item(const char* key, const char* name) { } static void draw_menu(lua_State* L) { - attron(A_BOLD|A_REVERSE|COLOR_PAIR(COLOR_PAIR_MENU)); + attron(A_BOLD|A_REVERSE); + color_set(COLOR_PAIR_MENU, NULL); for (int x = 0; x < COLS; ++x) mvaddch(LINES-1, x, ' '); menu_column = 2; |