Why Arabic text breaks in PDFs, and how to fix it
If you made or edited a PDF and the Arabic came out as separate letters, backwards words or empty boxes, the text itself is usually fine. The problem is how the PDF was laid out. The same applies to Urdu and Persian.
What you see
- Letters standing apart instead of joining: ب ي ت instead of بيت.
- Words or whole lines in reverse order.
- Numbers, dates and phone numbers flipped: 1234567-0300 instead of 0300-1234567.
- Empty boxes where letters should be.
- Text copied out of the PDF looks scrambled or reversed when you paste it.
Why it happens
- Letter shaping. An Arabic letter has different forms at the start, middle and end of a word and on its own, and some pairs merge, such as lam-alef (لا). The program that writes the PDF has to pick the right form for every letter. Many PDF generators and editors place only the basic form.
- Direction. Arabic runs right to left, but numbers and Latin words inside it run left to right. The Unicode bidirectional algorithm decides the order; tools that skip it reverse words or numbers.
- Fonts. The font has to contain the letters of your language, or you get boxes. Urdu needs letters such as ے ڑ ں; Persian needs پ چ ژ گ.
- Editing an existing PDF. A PDF stores shapes at fixed positions, not sentences. Tools that change text inside an existing PDF often cannot reshape Arabic, so edited lines break even when the original file was fine.
- Copy and paste. Some PDFs store ready-made letter shapes (presentation forms) or the visual order, so the copied text looks broken anywhere else.
How to fix it
- To add Arabic to an existing PDF (a form, a contract, a certificate), open it in Add text to a PDF, click where the text goes and type.
- Start from the text, not the broken PDF. Paste the original text into RTL PDF, choose a font and paper size, and download the PDF.
- If all you have is the broken PDF, copy its text and press "Check text". It finds ready-made and reversed letters and suggests a corrected text for you to review.
- If you use an AI assistant, add the RTL PDF connector (how) so the assistant makes the PDF with proper shaping.
- In a word processor, set the paragraph direction to right to left and pick a font that supports your language before you export to PDF.
Checklist before you print
- Letters join and words read right to left.
- Numbers, dates and phone numbers are in the right order.
- No empty boxes.
- Search the PDF for a word: if the search finds it, that is a good sign the text layer is sound.
لماذا تتقطع الحروف العربية في ملفات PDF، وكيف تصلحها
إذا صنعت ملف PDF أو عدّلته وظهرت العربية حروفا منفصلة أو كلمات مقلوبة أو مربعات فارغة، فالنص نفسه سليم في الغالب. المشكلة في طريقة تنضيد الملف. وينطبق الأمر نفسه على الأردية والفارسية.
ما الذي تراه
- حروف منفصلة بدل أن تتصل: ب ي ت بدل بيت.
- كلمات أو أسطر كاملة بترتيب معكوس.
- أرقام وتواريخ وأرقام هواتف مقلوبة: 1234567-0300 بدل 0300-1234567.
- مربعات فارغة مكان الحروف.
- نص منسوخ من الملف يظهر مبعثرا أو معكوسا عند لصقه.
لماذا يحدث ذلك
- تشكيل الحروف. للحرف العربي أشكال مختلفة في أول الكلمة ووسطها وآخرها ومنفردا، وبعض الحروف تتحد مثل لام الألف (لا). على البرنامج الذي يكتب ملف PDF أن يختار الشكل الصحيح لكل حرف، وكثير من برامج إنشاء ملفات PDF وتحريرها تضع الشكل الأساسي فقط.
- الاتجاه. العربية تُكتب من اليمين إلى اليسار، أما الأرقام والكلمات اللاتينية داخلها فمن اليسار إلى اليمين. خوارزمية الاتجاه الثنائي في يونيكود تحدد الترتيب الصحيح، والأدوات التي تتجاهلها تقلب الكلمات أو الأرقام.
- الخطوط. يجب أن يحتوي الخط على حروف لغتك، وإلا ظهرت مربعات. الأردية تحتاج حروفا مثل ے ڑ ں، والفارسية حروفا مثل پ چ ژ گ.
- تعديل ملف موجود. ملف PDF يحفظ أشكالا في مواضع ثابتة لا جملا. أدوات تعديل النص داخل ملف موجود كثيرا ما تعجز عن إعادة تشكيل العربية، فتتقطع الأسطر المعدلة حتى لو كان الملف الأصلي سليما.
- النسخ واللصق. بعض الملفات تحفظ الحروف بأشكالها الجاهزة (Presentation Forms) أو بترتيبها المرئي، فيظهر النص المنسوخ معطوبا في أي مكان آخر.
كيف تصلحها
- لإضافة نص عربي إلى ملف PDF موجود (نموذج أو عقد أو شهادة)، افتحه في أضف نصا إلى PDF، واضغط حيث تريد النص واكتب.
- ابدأ من النص لا من الملف المعطوب. الصق النص الأصلي في RTL PDF، واختر الخط ومقاس الورق، ثم نزّل الملف.
- إذا لم يكن لديك إلا الملف المعطوب، انسخ النص منه واضغط "افحص النص". تكشف الأداة الحروف الجاهزة والمقلوبة وتقترح نصا مصححا لتراجعه.
- إذا كنت تستخدم مساعدا ذكيا، أضف موصل RTL PDF (الطريقة) ليصنع المساعد الملف بتشكيل صحيح.
- في برامج تحرير النصوص، اجعل اتجاه الفقرة من اليمين إلى اليسار واختر خطا يدعم لغتك قبل التصدير إلى PDF.
قائمة فحص قبل الطباعة
- الحروف متصلة والكلمات تُقرأ من اليمين إلى اليسار.
- الأرقام والتواريخ وأرقام الهواتف بالترتيب الصحيح.
- لا مربعات فارغة.
- ابحث عن كلمة داخل الملف: إن وجدها البحث فهذه علامة جيدة على أن طبقة النص سليمة.