From 71229754040f3ffab5ffdb433207de0a9136be19 Mon Sep 17 00:00:00 2001 From: Til Schmitter Date: Fri, 8 May 2026 09:01:58 +0200 Subject: [PATCH] reduce transparency for nicer looking rasterized thumbnail fallbacks for now --- copyparty/ico.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/copyparty/ico.py b/copyparty/ico.py index 17fae2fd..e8a03a8c 100644 --- a/copyparty/ico.py +++ b/copyparty/ico.py @@ -48,7 +48,7 @@ class Ico(object): h = int(128.0 * h / w) w = 128 - img = Image.new("RGB", (w, h), "#" + c[:6]) + img = Image.new("RGBA", (w, h), "#" + c[:6] + 'aa') pb = ImageDraw.Draw(img) _, _, tw, th = pb.textbbox((0, 0), ext2, font_size=16) xy = (int((w - tw) / 2), int((h - th) / 2)) @@ -69,7 +69,7 @@ class Ico(object): h = int(64.0 * h / w) w = 64 - img = Image.new("RGB", (w, h), "#" + c[:6]) + img = Image.new("RGBA", (w, h), "#" + c[:6] + 'aa') pb = ImageDraw.Draw(img) try: _, _, tw, th = pb.textbbox((0, 0), ext)