I'm having problems typesetting Quranic verses numbers using ArabXeTeX. 1 or 2-digit numbers get properly displayed when using the dedicated macro ([[###]]) but 3-digit numbers aren't. It used to work nicely on my old system, but doesn't any more on my freshly re-installed one. Here's an example:

\setromanfont[BoldFont={Gentium Basic Bold},ItalicFont={Gentium Italic}]{Gentium}
\newfontfamily\arabicfont[Script=Arabic, Scale=2]{Scheherazade-Regular.ttf}




 ((وَالَّذِينَ اتَّخَذُوا مَسْجِدًا ضِرَارًا وَكُفْرًا وَتَفْرِيقًا بَيْنَ الْمُؤْمِنِينَ وَإِرْصَادًا لِّمَنْ حَارَبَ اللَّهَ وَرَسُولَهُ مِن قَبْلُ ۚ وَلَيَحْلِفُنَّ إِنْ أَرَدْنَا إِلَّا الْحُسْنَىٰ ۖ وَاللَّهُ يَشْهَدُ إِنَّهُمْ لَكَاذِبُونَ[[107]] لَا تَقُمْ فِيهِ أَبَدًا ۚ لَّمَسْجِدٌ أُسِّسَ عَلَى التَّقْوَىٰ مِنْ أَوَّلِ يَوْمٍ أَحَقُّ أَن تَقُومَ فِيهِ ۚ فِيهِ رِجَالٌ يُحِبُّونَ أَن يَتَطَهَّرُوا ۚ وَاللَّهُ يُحِبُّ الْمُطَّهِّرِينَ[[108]] أَفَمَنْ أَسَّسَ بُنْيَانَهُ عَلَىٰ تَقْوَىٰ مِنَ اللَّهِ وَرِضْوَانٍ خَيْرٌ أَم مَّنْ أَسَّسَ بُنْيَانَهُ عَلَىٰ شَفَا جُرُفٍ هَارٍ فَانْهَارَ بِهِ فِي نَارِ جَهَنَّمَ ۗ وَاللَّهُ لَا يَهْدِي الْقَوْمَ الظَّالِمِينَ[[109]]))


((قَالَ أَفَرَأَيْتُم مَّا كُنتُمْ تَعْبُدُونَ[[75]] أَنتُمْ وَآبَاؤُكُمُ الْأَقْدَمُونَ[[76]] فَإِنَّهُمْ عَدُوٌّ لِّي إِلَّا رَبَّ الْعَالَمِينَ[[77]] الَّذِي خَلَقَنِي فَهُوَ يَهْدِينِ[[78]] وَالَّذِي هُوَ يُطْعِمُنِي وَيَسْقِينِ [[79]] وَإِذَا مَرِضْتُ فَهُوَ يَشْفِينِ[[80]] وَالَّذِي يُمِيتُنِي ثُمَّ يُحْيِينِ[[81]] وَالَّذِي أَطْمَعُ أَن يَغْفِرَ لِي خَطِيئَتِي يَوْمَ الدِّينِ[[82]]))






Is anybody having the same issue? How could I correct that?


What I get

  • I think this is not a (La)TeX issue, not even a XeTeX one. Some time ago XeTeX used ICU for layout and then switched to HarfBuzz. Over the years there have been several posts that complain about numbers not being typeset properly in the number sign, always in the context of these layout engines (that are also used by other programs like libreoffice or firefox). Don't know whether these problems still exist, but it indicates that the current issue is not directly related to arabxetex, but rather to the combination of font and layout engine. – gernot Sep 11 '16 at 20:43
  • I remember having the same sort of issue in OpenOffice a few years ago, but it currently works fine on my installation of LibreOffice. The problem I'm having only happened after having upgraded my distro a few weeks ago. Also, something seems to have changed in how to invoke the Scheherazade font: before it was called by \newfontfamily\arabicfont[Script=Arabic]{Scheherazade} but this doesn't work any more (see the example). I do not have this number issue with the Amiri font, so I am wondering if it's not some compatibility issue related to Scheherazade. – Abu Zayd Sep 11 '16 at 20:46
  • This not occur if we use Amiri font – Salim Bou Sep 12 '16 at 17:08
  • Yes, the issue seems to happen with Scheherazade only. – Abu Zayd Sep 12 '16 at 19:21

Use the included Amiri font. It solves this problem.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.