From 7b07cb8f8e172d8cda2754b3269e40d9a2c6def9 Mon Sep 17 00:00:00 2001 From: GetAway Date: Thu, 12 Oct 2017 15:14:04 +0200 Subject: [PATCH] msgbox: use OFFSET_MIN for better bg detection --- msgbox.c | 2 +- text.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/msgbox.c b/msgbox.c index 14ecba5..f6021e2 100644 --- a/msgbox.c +++ b/msgbox.c @@ -17,7 +17,7 @@ typeof (b) __b = (b); \ __a > __b ? __a : __b; }) -#define M_VERSION 2.11 +#define M_VERSION 2.12 #define NCF_FILE "/var/tuxbox/config/neutrino.conf" #define HDF_FILE "/tmp/.msgbox_hidden" diff --git a/text.c b/text.c index c57c07f..b1e81c2 100644 --- a/text.c +++ b/text.c @@ -281,7 +281,7 @@ int RenderChar(FT_ULong currentchar, int _sx, int _sy, int _ex, int color) if (_sx + sbit->xadvance >= _ex) return -1; /* limit to maxwidth */ uint32_t fgcolor; - uint32_t bgcolor = *(lbb + (sy + _sy - _d - 1) * swidth + (sx + _sx + sbit->left)); + uint32_t bgcolor = *(lbb + (sy + _sy - _d - 1) * swidth + (sx + _sx + OFFSET_MIN + sbit->left)); if ( color == -2) /* flash */ fgcolor = bgcolor; else -- 2.39.5