Skip to content

Instantly share code, notes, and snippets.

View erfanhs's full-sized avatar
🎯
Focusing

Erfan Harirsaz erfanhs

🎯
Focusing
  • Mashhad, Iran
View GitHub Profile
@amrza
amrza / run.py
Last active July 8, 2024 08:13
How to write RTL(Arabic/Persian) text on images in python.
# Tested on Python 3.6.1
# install: pip install --upgrade arabic-reshaper
import arabic_reshaper
# install: pip install python-bidi
from bidi.algorithm import get_display
# install: pip install Pillow
from PIL import ImageFont