I use Ubuntu 14.0.4
. I want to use a file with UTF8 by a command of ImageMagick. Here you can see:
If the UTF-8 text you wanting to draw has already been generated you can read it directly from a file using '@filename'.For example here I create a Chinese label from a UTF-8 encoded Chinese text file (without a final newline in the file).
convert -background lightblue -fill blue -pointsize 48 \
-font ZenKaiUni label:@chinese_words.utf8 label_utf8.gif
Now I test a command that is look like above command for a text file with name label1.txt
which it's content is a Persian word:
سلام
Command is:
convert -background lightblue -fill blue -pointsize 48 label:@label1.txt label_utf8.png
But I got this image:
You can see ?
characters instead of desired ones. How can I solve this problem?