Convert Hebrew text to image using imagemagick

I need to convert text to image. Using imagemagick, I can do this. However, part or all of the text may be in Hebrew (RTL). This means that the Hebrew words are laid back. If I were sure that the text was only in Hebrew, I would just change the text before sending it to ImageMagick. However, this solution will not work if part of the text is in English.

Does anyone know how to do this?

PS I do not intend to use ImageMagick if a better way appears. However, the solution should work for both Linux and Windows (I could live with a solution other than Windows, but a solution for several OSs is preferable).

Thank you Nive

+3
source share
2 answers

It seems your real problem is to re-order bidirectional text for imagemagick. The challenge for the bidirectional Unicode algorithm. See http://unicode.org/reports/tr9/ This report lists two reference implementations. Or look at this: http://fribidi.org/

+1
source

Source: https://habr.com/ru/post/1711446/


All Articles