summaryrefslogtreecommitdiff
path: root/src/bin/options_colors.c
diff options
context:
space:
mode:
authorBoris Faure <billiob@gmail.com>2018-01-15 23:28:18 +0100
committerBoris Faure <billiob@gmail.com>2018-01-15 23:28:18 +0100
commit8c09ee5c88069d8f343913f62688aade0a038131 (patch)
treead5e8e611c29f4101c4cda52e8849e66d561b4dc /src/bin/options_colors.c
parentf33e898e291e95d133358e5f79083fb374eaa1b4 (diff)
options_colors: compute pre-multiplied colors
Diffstat (limited to 'src/bin/options_colors.c')
-rw-r--r--src/bin/options_colors.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/bin/options_colors.c b/src/bin/options_colors.c
index 88bea6e..192c224 100644
--- a/src/bin/options_colors.c
+++ b/src/bin/options_colors.c
@@ -92,9 +92,9 @@ _cb_op_color_chg(void *data,
92 continue; 92 continue;
93 if (ctx->colitem[j][i] == ctx->curitem) 93 if (ctx->colitem[j][i] == ctx->curitem)
94 { 94 {
95 config->colors[(j * 12) + i].r = r; 95 config->colors[(j * 12) + i].r = r * a / 256;
96 config->colors[(j * 12) + i].g = g; 96 config->colors[(j * 12) + i].g = g * a / 256;
97 config->colors[(j * 12) + i].b = b; 97 config->colors[(j * 12) + i].b = b * a / 256;
98 config->colors[(j * 12) + i].a = a; 98 config->colors[(j * 12) + i].a = a;
99 termio_config_update(ctx->term); 99 termio_config_update(ctx->term);
100 config_save(config, NULL); 100 config_save(config, NULL);