From 341c22d2a593040c558de5f9b82d3f740207d82f Mon Sep 17 00:00:00 2001 From: Michael Drake Date: Wed, 25 Oct 2017 17:49:25 +0100 Subject: [PATCH] Windows: Use bitmap width as minimum width, since content width may be 0. --- frontends/windows/bitmap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontends/windows/bitmap.c b/frontends/windows/bitmap.c index 1266adb61..eed3d3a15 100644 --- a/frontends/windows/bitmap.c +++ b/frontends/windows/bitmap.c @@ -326,7 +326,7 @@ bitmap_render(struct bitmap *bitmap, struct hlcache_handle *content) .plot = &win_plotters }; - width = min(content_get_width(content), 1024); + width = min(max(content_get_width(content), bitmap->width), 1024); height = ((width * bitmap->height) + (bitmap->width / 2)) / bitmap->width;