I'm making a project were i make a video out of reddit post, part of it is getting a paragraph and adding a background image to it, i found out I could do it with pillow but my text overflows.
Code:
from PIL import Image , ImageDraw, ImageFont
text = "Some background: my friend lost her father and her two older sisters in a tragic car accident 7 years ago. " \
"I was her shoulder to cry on. She became attached to me as a second sister " \
"and grew closer to her only living sibling (her brother)."
new = Image.new('RGB', (1000, 1000), color=(3, 252, 232))
d = ImageDraw.Draw(new)
fnt = ImageFont.truetype("comicbd.ttf", 25)
d.text((0, 0), text, font=fnt, fill=(255, 255, 255))
new.show('img.jpg')
image of overflow: