Skip to content

Warn about duplicate Raqm text preprocessing - #9914

Open
cananoo wants to merge 1 commit into
python-pillow:mainfrom
cananoo:docs/9907-raqm-text-processing
Open

Warn about duplicate Raqm text preprocessing#9914
cananoo wants to merge 1 commit into
python-pillow:mainfrom
cananoo:docs/9907-raqm-text-processing

Conversation

@cananoo

@cananoo cananoo commented Aug 27, 2026

Copy link
Copy Markdown

Fixes #9907.

Pillow uses libraqm to perform shaping and bidirectional text layout when it is available. This adds a note to the ImageDraw documentation warning that pre-processing text with arabic_reshaper and python-bidi in that case applies the same processing twice and can produce incorrect output.

The note also points readers to PIL.features.check("raqm") so applications can choose the appropriate behavior at runtime.

Validation:

  • Built the full documentation site with Sphinx using the released Pillow wheel for autodoc imports.
  • Ran git diff --check.

I used OpenAI Codex to assist with investigating and preparing this change, and reviewed the resulting documentation before submission.

@radarhere radarhere changed the title docs: warn about duplicate Raqm text preprocessing Warn about duplicate Raqm text preprocessing Aug 27, 2026
@cananoo
cananoo marked this pull request as ready for review August 28, 2026 02:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Docs: warn that pre-applying arabic_reshaper + python-bidi corrupts text on a Raqm build

2 participants