Answer the question
In order to leave comments, you need to log in
I have a small problem with the pillow library, how to display exactly a numeric variable?
The problem is that: I use the Pillow library to display text on a photo, but there is such a problem that when I display the balance variable, which is numeric, I get an error:
Traceback (most recent call last):
File "C:\Users\Lenovo\pil.py", line 12, in <module>
idraw.text((110, 20), balance, font = headline)
File "C:\Users\Lenovo\AppData\Local\Programs\Python\Python39\lib\site-packages\PIL\ImageDraw.py", line 289, in text
if self._multiline_check(text):
File "C:\Users\Lenovo\AppData\Local\Programs\Python\Python39\lib\site-packages\PIL\ImageDraw.py", line 264, in _multiline_check
return split_character in text
TypeError: argument of type 'int' is not iterable
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question