Skip to content

Warn against pre-processing text with arabic_reshaper and python-bidi on Raqm builds - #10408

Open
SudiptoKumar wants to merge 1 commit into
python-pillow:mainfrom
SudiptoKumar:docs/raqm-preprocessing-warning
Open

SudiptoKumar wants to merge 1 commit into
python-pillow:mainfrom
SudiptoKumar:docs/raqm-preprocessing-warning

Conversation

@SudiptoKumar

Copy link
Copy Markdown

Adds the warning proposed in #9907 to the libraqm bullet in the building-from-source docs, where the bidirectional/shaping sentence quoted in the issue lives.

On a Raqm build, Pillow already performs bidirectional reordering (FriBiDi) and shaping (HarfBuzz). The widely-copied recipe of pre-applying arabic_reshaper and python-bidi — still necessary on builds without Raqm — therefore processes the text twice: it renders incorrectly, and the reshape step itself rewrites the string (lam-alef merged into a single presentation form, diacritics dropped). The new bullet states this and points readers at the conditional form:

if not features.check("raqm"):
    text = get_display(arabic_reshaper.reshape(text))

Docs-only change, one bullet added, no other files touched. Happy to move or reword the note if another location (e.g. the features reference or the text-drawing docs) is preferred.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant