This commit is contained in:
j 2024-05-22 11:04:18 +02:00
parent d271e9ba32
commit 401203cd83

View file

@ -135,7 +135,7 @@ def make_title(title):
width = 852 width = 852
height = 480 height = 480
image = Image.new("RGB", (width, height), "black") image = Image.new("RGB", (width, height), "black")
font = ImageFont.truetype("/usr/share/fonts/truetype/roboto/unhinted/RobotoTTF/Roboto-Regular.ttf", size=30) font = ImageFont.truetype("/usr/share/fonts/truetype/roboto/unhinted/RobotoTTF/Roboto-Bold.ttf", size=30)
draw = ImageDraw.Draw(image) draw = ImageDraw.Draw(image)
_, _, font_width, font_height = font.getbbox(title) _, _, font_width, font_height = font.getbbox(title)
new_width = (width - font_width) / 2 new_width = (width - font_width) / 2