From ec071d4e8aa82c60928407f16ae7aa65d78c666d Mon Sep 17 00:00:00 2001 From: kichikuou Date: Wed, 14 May 2025 12:46:30 +0900 Subject: [PATCH] dt_drawtext_col: Fix blend mode This fixes #66. It was a regression by commit 6b646b3. --- modules/lib/drawtext.c | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/lib/drawtext.c b/modules/lib/drawtext.c index 8bbdb5a..de87d23 100644 --- a/modules/lib/drawtext.c +++ b/modules/lib/drawtext.c @@ -71,6 +71,7 @@ int dt_drawtext_col(SDL_Surface *sf, int x, int y, char *buf, int r, int g, int if (glyph == NULL) return 0; SDL_Rect rect = {x, y, glyph->w, glyph->h}; + SDL_SetSurfaceBlendMode(glyph, SDL_BLENDMODE_NONE); SDL_BlitSurface(glyph, NULL, sf, &rect); SDL_FreeSurface(glyph); return rect.w;