javadr / quran

Simplifying The Holy Quran Typesetting in XeLaTeX.
22 stars 5 forks source link

small alif on top of letters instead of next to them #4

Closed Shubbak closed 3 years ago

Shubbak commented 3 years ago

I love this package! Two possible improvements as far as the actual typestting is concerned:

  1. If you typeset an ayah which has a small alif (الألف الخنجرية) this alif is typeset on top of the letter before it instead of next to it. See pictures and also example below (first line is correct, second line is incorrect): مَـٰلِكِ مَٰلِكِ This can of course be a huge deal, since an alif on top of a waw like الصَّلَوٰةِ means that you pronounce the waw as an alif, but if you are supposed to pronounce a waw and then an alif, it should be (I didn't quite manage it, but you get the point): الصَْلَوَـٰتِ and those two mean different things.

  2. It would be nice if the small و and ي after the pronoun- ـه were typeset. (See pictures)

1 2

Thanks

javadr commented 3 years ago

You know, I've used the minimalist version of the Quran's text. BTW, I'll add it to the next version.

Shubbak commented 3 years ago

Thank you!

javadr commented 3 years ago

From version 1.8, the uthmani option will typeset the text of the Quran with more diacritical marks. See the below picture. image I will update it in the near future to the CTAN.

Shubbak commented 3 years ago

Fantastic! Barakallahu feek. I've been wondering if in the future you will try to optimize the position of the small alif as well? It's just if you for example read حَـٰفِظُوا۟ عَلَى ٱلصَّلَوَ ٰ⁠تِ وَٱلصَّلَوٰةِ ٱلۡوُسۡطَىٰ وَقُومُوا۟ لِلَّهِ قَـٰنِتِینَ you'll notice that the only difference between the two words ٱلصَّلَوَ ٰ⁠تِ and وَٱلصَّلَوٰةِ is that one has the alif on top of the و and the other next to it but they're read differntly and give a different meaning. So you see that I'm by no means nitpicking, it is an important improvement. BTW I copied this text from the android app "Quran Android" maybe this will help you with finding a text source where the small alif is in the correct position

And now for some actual nitpicking that is not very important and I just want to throw it into the room and you may think about it: you know the other symbols apart from the common ( َ ً ُ ٌ ِ ٍ ّ ْ ) like for example the one on top of this alif: ٱ which tells you the alif is spoken when beginning and dropped when continuing from the last word or the symbol on this alif: ا۠ which tells you that you say the alif when stopping on the word and don't when continuing with the next word or the symbol on this alif: ا۟ which tells you that this alif is dropped in all cases.. you see what I mean. Maybe you can think about adding them (they are also present when copying from Quran Android)

Keep up the great work and jazakallahu khayran!

javadr commented 3 years ago

Your first point is totally a font issue. Look at the following pictures: Screenshot from 2020-10-17 08-04-50

Screenshot from 2020-10-17 08-06-20

As you can see, the Amiri Quran font would be your desired font.

If I get your second point correctly, the version 1.8 of the package supports it via uthmani option. See below (look at ادعوا): Screenshot from 2020-10-17 08-14-37

Shubbak commented 3 years ago

Fantastic, barakallahu feek!

Shubbak commented 3 years ago

It didn't work for me, maybe I'm doing something wrong. This one is with Amiri Quran

\setdefaultlanguage{arabic}
\setotherlanguage{german}
\newfontfamily\arabicfont[Script=Arabic,Mapping=arabicdigits]{Amiri Quran}
\newfontfamily\arabicfontsf[Script=Arabic,Mapping=arabicdigits]{Amiri Quran}
\newfontfamily\arabicfonttt[Script=Arabic,Mapping=arabicdigits]{Amiri Quran}

1

and this one is with Amiri:

\setdefaultlanguage{arabic}
\setotherlanguage{german}
\newfontfamily\arabicfont[Script=Arabic,Mapping=arabicdigits]{Amiri}
\newfontfamily\arabicfontsf[Script=Arabic,Mapping=arabicdigits]{Amiri}
\newfontfamily\arabicfonttt[Script=Arabic,Mapping=arabicdigits]{Amiri}

2

as you can see it makes it even worse because it doesn't typeset the جل جلاله and the name of Allah correctly any more.

Am I doing something wrong?

javadr commented 3 years ago

I think you're using the old version of the package (prior to 1.8), so update your tex distribution. Screenshot from 2020-10-18 09-10-56

Actually, the issue with جل جلاله and الله is related to the Amiri Quran font. Make sure you're using the latest version of Amiri. If the problem exists, I strongly suggest you contact Khaled Hosny (@khaledhosny) the creator of this beautiful font and ask him to fix it.

khaledhosny commented 3 years ago

Amiri Quran should be used for the Quranic text only since only contains only a minimum subset of the characters that are used in the Quran and makes other stylistic choices that are suitable only for the Quran. For the regular Arabic text, Amiri should be used.

khaledhosny commented 3 years ago

The small alef should be placed over tatweel (U+0640) when it comes between connected letters, e.g. the first one in السموت, or over NBSP (U+00A0) when between unconnected letters, e.g. the second one in السموت. Otherwise it is placed directly over the letter as over the waw in الصلوة or the alef maksura in اتقى.

The latest versions of Amiri should always be used with the latest Quranic text from https://github.com/khaledhosny/quran-data since I sometimes update the font and the data to follow the best practices for representing Quran text in Unicode.

Shubbak commented 3 years ago

Jazakumallahu khayran the two of you. The issue has been resolved in version 1.8 for quran the Amiri font itself worked as well (for what I was looking for) As a matter of fact, for my untrained eye both fonts looked exactly the same, except for the things I mentioned which are outside the Quranic text.