I'm having trouble drawing multilingual text using PIL. Say I want to draw a text - "γ² γ γ γͺ - Hiragana, νλΌκ°λ". But the PIL function ImageDraw.text () only accepts one font at a time, so I cannot draw this text correctly because it requires the sharing of English, Japanese, and Korean fonts.
So far, I have not been able to find a simple solution, for example, transferring several fonts to PIL so that it can select the appropriate font for each Unicode character (for example, modern SDKs or web browsers).
I think I should iterate over each character and determine which font to use for each character. But I can't help but think that there should be an easier way to do this.
Am I going in the right direction? Is there an easier way?
PS) It is good to use a different language or a different image library if there is a much better solution.
fonts unicode imaging python-imaging-library cjk
redism
source share