From d69a0eac0c09f57f52a07fff0002bca9120ff2bc Mon Sep 17 00:00:00 2001 From: Uri Shaked Date: Mon, 26 May 2025 19:35:31 +0300 Subject: [PATCH] fix(logo): support to longer shuttle names (e.g. TTCAD25a) --- logo.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/logo.py b/logo.py index 8b0ca16..43fa9e0 100755 --- a/logo.py +++ b/logo.py @@ -39,7 +39,13 @@ class LogoGenerator: f.set_variation_by_axes([700]) return f - draw.text((2, -15), shuttle, fill=255, font=font(88)) + shuttle_font_size = 88 + shuttle_y_offset = -15 + if len(shuttle) > 4: + shuttle = shuttle[:-1].upper() + shuttle[-1] + shuttle_font_size = 44 + shuttle_y_offset = 10 + draw.text((2, shuttle_y_offset), shuttle, fill=255, font=font(shuttle_font_size)) draw.text((2, 68), commit[:8], fill=255, font=font(44)) draw.text((2, 107), commit[8:18], fill=255, font=font(35)) draw.text((1, 137), commit[18:29], fill=255, font=font(32))