From fec0568b29e326a269f15cd12c90b6e43c69c39b Mon Sep 17 00:00:00 2001 From: Aaron van Geffen Date: Thu, 5 Oct 2017 13:22:42 +0200 Subject: [PATCH] Shade black backgrounds differently (e.g. IME) --- src/openrct2/drawing/string.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/openrct2/drawing/string.c b/src/openrct2/drawing/string.c index a66f2dc4f8..028a0dd081 100644 --- a/src/openrct2/drawing/string.c +++ b/src/openrct2/drawing/string.c @@ -805,6 +805,11 @@ static void ttf_draw_string_raw_ttf(rct_drawpixelinfo *dpi, const utf8 *text, te // Centre of the glyph: use full colour. *dst = colour; } + else if (*dst < 10 && *src > 50) + { + // For black backgrounds, hint using grey pixels. + *dst = 13; + } else if (*src > 70) { // Simulate font hinting by shading the background colour instead.