diff options
Diffstat (limited to 'Master/texmf-dist/tex/lualatex/arabluatex/arabluatex_voc.lua')
-rw-r--r-- | Master/texmf-dist/tex/lualatex/arabluatex/arabluatex_voc.lua | 112 |
1 files changed, 70 insertions, 42 deletions
diff --git a/Master/texmf-dist/tex/lualatex/arabluatex/arabluatex_voc.lua b/Master/texmf-dist/tex/lualatex/arabluatex/arabluatex_voc.lua index 681995277ec..02c3febe93c 100644 --- a/Master/texmf-dist/tex/lualatex/arabluatex/arabluatex_voc.lua +++ b/Master/texmf-dist/tex/lualatex/arabluatex/arabluatex_voc.lua @@ -201,6 +201,12 @@ hamza = { {a="(A)(')(u)", b="aآؤ%3"}, -- historic madda {a="(A)(')", b="aآء"}, -- historic madda -- initial (needs both ^ and %W patterns) + -- 'aw: the diphthong is to be resoved into 'awi' (next 4 lines) + {a="^('aw)(%s)(['][%_%^%.]?[l'btjghxdrzs`fqkmnwy]%-)", b="%1i%2%3"}, + {a="(%W)('aw)(%s)(['][%_%^%.]?[l'btjghxdrzs`fqkmnwy]%-)", b="%1%2i%3%4"}, + {a="^('aw)(%s)([%(%[%|%<]?\"?[uai])", b="%1i%2%3"}, + {a="(%W)('aw)(%s)([%(%[%|%<]?\"?[uai])", b="%1%2i%3%4"}, + -- then the 'initial' rules for the remaining cases {a="^(')([ua])", b="أ%2"}, {a="^(')(i)", b="إ%2"}, {a="(%W)(')([ua])", b="%1أ%3"}, @@ -209,29 +215,29 @@ hamza = { -- ^say'aN and .zim'aN are special orthographies {a="(%^say)(%')(aN)", b="%1ئ%3"}, {a="(.zi?m)(%')(aN)", b="%1ئ%3"}, - {a="([^uai])(')([uai]N?)$", b="%1ء%3"}, - {a="([^uai])(')([uai]N?)(%W)", b="%1ء%3%4"}, + {a="([^uai])(')([uai][^%.%^%_]N?)$", b="%1ء%3"}, + {a="([^uai])(')([uai][^%.%^%_]N?)(%W)", b="%1ء%3%4"}, -- u - {a="(u)(')([uai]N?)$", b="%1ؤ%3"}, - {a="(u)(')([uai]N?)(%W)", b="%1ؤ%3%4"}, + {a="(u)(')([uai][^%.%^%_]N?)$", b="%1ؤ%3"}, + {a="(u)(')([uai][^%.%^%_]N?)(%W)", b="%1ؤ%3%4"}, {a="(u)(')$", b="%1ؤ"}, {a="(u)(')(%W)", b="%1ؤ%3"}, -- a {a="(a)(')(A)$", b="%1آ"}, {a="(a)(')(A)(%W)", b="%1آ%4"}, - {a="(a)(')([u]N?)$", b="%1أ%3"}, - {a="(a)(')([u]N?)(%W)", b="%1أ%3%4"}, + {a="(a)(')([u][^%.%^%_]N?)$", b="%1أ%3"}, + {a="(a)(')([u][^%.%^%_]N?)(%W)", b="%1أ%3%4"}, {a="(a)(')(a)$", b="%1أ%3"}, {a="(a)(')(a)(%W)", b="%1أ%3%4"}, {a="(a)(')(aN)$", b="%1أً"}, {a="(a)(')(aN)(%W)", b="%1أً%4"}, - {a="(a)(')([i]N?)$", b="%1إ%3"}, - {a="(a)(')([i]N?)(%W)", b="%1إ%3%4"}, + {a="(a)(')([i][^%.%^%_]N?)$", b="%1إ%3"}, + {a="(a)(')([i][^%.%^%_]N?)(%W)", b="%1إ%3%4"}, {a="(a)(')$", b="%1أ"}, {a="(a)(')(%W)", b="%1أ%3"}, -- i - {a="(i)(')([uai]N?)$", b="%1ئ%3"}, - {a="(i)(')([uai]N?)(%W)", b="%1ئ%3%4"}, + {a="(i)(')([uai][^%.%^%_]N?)$", b="%1ئ%3"}, + {a="(i)(')([uai][^%.%^%_]N?)(%W)", b="%1ئ%3%4"}, {a="(i)(')$", b="%1ئ"}, {a="(i)(')(%W)", b="%1ئ%3"}, -- @@ -292,6 +298,12 @@ hamzaeasy = { -- differences marked below with 'easy' {a="(A)(')", b="aاء"}, -- historic madda --easy (end) -- initial (needs both ^ and %W patterns) + -- 'aw: the diphthong is to be resoved into 'awi' (next 4 lines) + {a="^('aw)(%s)(['][%_%^%.]?[l'btjghxdrzs`fqkmnwy]%-)", b="%1i%2%3"}, + {a="(%W)('aw)(%s)(['][%_%^%.]?[l'btjghxdrzs`fqkmnwy]%-)", b="%1%2i%3%4"}, + {a="^('aw)(%s)([%(%[%|%<]?\"?[uai])", b="%1i%2%3"}, + {a="(%W)('aw)(%s)([%(%[%|%<]?\"?[uai])", b="%1%2i%3%4"}, + -- then the 'initial' rules for the remaining cases {a="^(')([ua])", b="أ%2"}, {a="^(')(i)", b="إ%2"}, {a="(%W)(')([ua])", b="%1أ%3"}, @@ -300,29 +312,29 @@ hamzaeasy = { -- differences marked below with 'easy' -- ^say'aN and .zim'aN are special orthographies {a="(%^say)(%')(aN)", b="%1ئ%3"}, {a="(.zi?m)(%')(aN)", b="%1ئ%3"}, - {a="([^uai])(')([uai]N?)$", b="%1ء%3"}, - {a="([^uai])(')([uai]N?)(%W)", b="%1ء%3%4"}, + {a="([^uai])(')([uai][^%.%^%_]N?)$", b="%1ء%3"}, + {a="([^uai])(')([uai][^%.%^%_]N?)(%W)", b="%1ء%3%4"}, -- u - {a="(u)(')([uai]N?)$", b="%1ؤ%3"}, - {a="(u)(')([uai]N?)(%W)", b="%1ؤ%3%4"}, + {a="(u)(')([uai][^%.%^%_]N?)$", b="%1ؤ%3"}, + {a="(u)(')([uai][^%.%^%_]N?)(%W)", b="%1ؤ%3%4"}, {a="(u)(')$", b="%1ؤ"}, {a="(u)(')(%W)", b="%1ؤ%3"}, -- a {a="(a)(')(A)$", b="%1آ"}, {a="(a)(')(A)(%W)", b="%1آ%4"}, - {a="(a)(')([u]N?)$", b="%1أ%3"}, - {a="(a)(')([u]N?)(%W)", b="%1أ%3%4"}, + {a="(a)(')([u][^%.%^%_]N?)$", b="%1أ%3"}, + {a="(a)(')([u][^%.%^%_]N?)(%W)", b="%1أ%3%4"}, {a="(a)(')(a)$", b="%1أ%3"}, {a="(a)(')(a)(%W)", b="%1أ%3%4"}, {a="(a)(')(aN)$", b="%1أً"}, {a="(a)(')(aN)(%W)", b="%1أً%4"}, - {a="(a)(')([i]N?)$", b="%1إ%3"}, - {a="(a)(')([i]N?)(%W)", b="%1إ%3%4"}, + {a="(a)(')([i][^%.%^%_]N?)$", b="%1إ%3"}, + {a="(a)(')([i][^%.%^%_]N?)(%W)", b="%1إ%3%4"}, {a="(a)(')$", b="%1أ"}, {a="(a)(')(%W)", b="%1أ%3"}, -- i - {a="(i)(')([uai]N?)$", b="%1ئ%3"}, - {a="(i)(')([uai]N?)(%W)", b="%1ئ%3%4"}, + {a="(i)(')([uai][^%.%^%_]N?)$", b="%1ئ%3"}, + {a="(i)(')([uai][^%.%^%_]N?)(%W)", b="%1ئ%3%4"}, {a="(i)(')$", b="%1ئ"}, {a="(i)(')(%W)", b="%1ئ%3"}, -- @@ -415,27 +427,32 @@ tanwineasy = { -- 'easy' requires some lines to be taken out: trigraphs = { -- trigraphs or more -- 'llatI / 'llad_I {a="^'ll(a)([%_]?[dt])", b="الّ%1%2"}, - {a="([%s%-])'ll(a)([%_]?[dt])", b="%1الّ%2%3"}, + {a="([%(%[%|%<%s%-])'ll(a)([%_]?[dt])", b="%1الّ%2%3"}, --p + -- law: the diphthong is to be resoved into 'awi' (next 4 lines) + {a="^(law)(%s)(['][%_%^%.]?[l'btjghxdrzs`fqkmnwy]%-)", b="%1i%2%3"}, + {a="(%W)(law)(%s)(['][%_%^%.]?[l'btjghxdrzs`fqkmnwy]%-)", b="%1%2i%3%4"}, + {a="^(law)(%s)([%(%[%|%<]?\"?[uai])", b="%1i%2%3"}, + {a="(%W)(law)(%s)([%(%[%|%<]?\"?[uai])", b="%1%2i%3%4"}, -- al- + lām {a="^(a)l%-(l)", b="ا%1ل%2%2"}, - {a="([%s%-])(a)l%-(l)", b="%1ا%2ل%3%3"}, + {a="([%(%[%|%<%s%-])(a)l%-(l)", b="%1ا%2ل%3%3"}, --p -- al- + solar consonant {a="^(a)l%-([%_%^%.]?[tdrzsn])", b="ا%1ل%2%2"}, - {a="([%s%-])(a)l%-([%_%^%.]?[tdrzsn])", b="%1ا%2ل%3%3"}, + {a="([%(%[%|%<%s%-])(a)l%-([%_%^%.]?[tdrzsn])", b="%1ا%2ل%3%3"}, --p -- assim. art. + solar consonant {a="^(a)([%_%^%.]?[tdrzsn])%-", b="ا%1ل%2"}, - {a="([%s%-])(a)([%_%^%.]?[tdrzsn])%-", b="%1ا%2ل%3"}, + {a="([%(%[%|%<%s%-])(a)([%_%^%.]?[tdrzsn])%-", b="%1ا%2ل%3"}, --p -- al- + initial unstable hamza {a="^(a)l%-(\")([uai])", b="ا%1ل%3ٱ"}, - {a="([%s%-])(a)l%-(\")([uai])", b="%1ا%2ل%4ٱ"}, + {a="([%(%[%|%<%s%-])(a)l%-(\")([uai])", b="%1ا%2ل%4ٱ"}, --p {a="^(a)l%-([uai])", b="ا%1ل%2ا"}, - {a="([%s%-])(a)l%-([uai])", b="%1ا%2ل%3ا"}, + {a="([%(%[%|%<%s%-])(a)l%-([uai])", b="%1ا%2ل%3ا"}, --p -- li-/la- + art. + initial unstable hamza is a special orthography {a="l([ai])%-l%-(\")([uai])", b="ل%1ل%3ٱ"}, {a="l([ai])%-l%-([uai])", b="ل%1ل%2ا"}, -- al- + lunar consonant (i.e. what remains) {a="^(a)l%-", b="ا%1ل"}, - {a="([%s%-])(a)l%-", b="%1ا%2ل"}, + {a="([%(%[%|%<%s%-])(a)l%-", b="%1ا%2ل"}, --p -- diphthongs to be resolved before ʾalif conjunctionis {a="(aW)(%s)(['][%_%^%.]?[l'btjghxdrzs`fqkmnwy]%-)", b="awuا%2%3"}, {a="(aw)(%s)(['][%_%^%.]?[l'btjghxdrzs`fqkmnwy]%-)", b="%1u%2%3"}, @@ -467,7 +484,10 @@ trigraphs = { -- trigraphs or more -- words ending in -āT with silent wāw/yāʾ {a="(_a)UA", b="%1وا"}, {a="(_a)U", b="%1و"}, - {a="(_a)I", b="%1ي"}, + {a="(_a)I", b="%1ي"} +} + +idgham = { -- assimilations {a="(n)(%s)([rlmnwy])", b="%1%2%3%3"} } @@ -477,27 +497,32 @@ trigraphseasy = { -- differences marked below with 'easy' {a="l%-l_ah", b="l-ll_ah"}, -- 'llatI / 'llad_I {a="^'ll(a)([%_]?[dt])", b="الّ%1%2"}, - {a="([%s%-])'ll(a)([%_]?[dt])", b="%1الّ%2%3"}, + {a="([%(%[%|%<%s%-])'ll(a)([%_]?[dt])", b="%1الّ%2%3"}, --p + -- law: the diphthong is to be resoved into 'awi' (next 4 lines) + {a="^(law)(%s)(['][%_%^%.]?[l'btjghxdrzs`fqkmnwy]%-)", b="%1i%2%3"}, + {a="(%W)(law)(%s)(['][%_%^%.]?[l'btjghxdrzs`fqkmnwy]%-)", b="%1%2i%3%4"}, + {a="^(law)(%s)([%(%[%|%<]?\"?[uai])", b="%1i%2%3"}, + {a="(%W)(law)(%s)([%(%[%|%<]?\"?[uai])", b="%1%2i%3%4"}, -- al- + lām (easy) {a="^(a)l%-(l)", b="ا%1ل%2"}, - {a="([%s%-])(a)l%-(l)", b="%1ا%2ل%3"}, + {a="([%(%[%|%<%s%-])(a)l%-(l)", b="%1ا%2ل%3"}, --p -- al- + solar consonant (easy) {a="^(a)l%-([%_%^%.]?[tdrzsn])", b="ا%1ل%2"}, - {a="([%s%-])(a)l%-([%_%^%.]?[tdrzsn])", b="%1ا%2ل%3"}, + {a="([%(%[%|%<%s%-])(a)l%-([%_%^%.]?[tdrzsn])", b="%1ا%2ل%3"}, --p -- assim. art. + solar consonant (easy) {a="^(a)([%_%^%.]?[tdrzsn])%-", b="ا%1ل"}, - {a="([%s%-])(a)([%_%^%.]?[tdrzsn])%-", b="%1ا%2ل"}, + {a="([%(%[%|%<%s%-])(a)([%_%^%.]?[tdrzsn])%-", b="%1ا%2ل"}, --p -- al- + initial unstable hamza {a="^(a)l%-(\")([uai])", b="ا%1ل%3ٱ"}, - {a="([%s%-])(a)l%-(\")([uai])", b="%1ا%2ل%4ٱ"}, + {a="([%(%[%|%<%s%-])(a)l%-(\")([uai])", b="%1ا%2ل%4ٱ"}, --p {a="^(a)l%-([uai])", b="ا%1ل%2ا"}, - {a="([%s%-])(a)l%-([uai])", b="%1ا%2ل%3ا"}, + {a="([%(%[%|%<%s%-])(a)l%-([uai])", b="%1ا%2ل%3ا"}, --p -- li-/la- + art. + initial unstable hamza is a special orthography {a="l([ai])%-l%-(\")([uai])", b="ل%1ل%3ٱ"}, {a="l([ai])%-l%-([uai])", b="ل%1ل%2ا"}, -- al- + lunar consonant (i.e. what remains) {a="^(a)l%-", b="ا%1ل"}, - {a="([%s%-])(a)l%-", b="%1ا%2ل"}, + {a="([%(%[%|%<%s%-])(a)l%-", b="%1ا%2ل"}, --p -- diphthongs to be resolved before ʾalif conjunctionis {a="(aW)(%s)(['][%_%^%.]?[l'btjghxdrzs`fqkmnwy]%-)", b="awuا%2%3"}, {a="(aw)(%s)(['][%_%^%.]?[l'btjghxdrzs`fqkmnwy]%-)", b="%1u%2%3"}, @@ -529,9 +554,7 @@ trigraphseasy = { -- differences marked below with 'easy' -- words ending in -āT with silent wāw/yāʾ {a="(_a)UA", b="%1وا"}, {a="(_a)U", b="%1و"}, - {a="(_a)I", b="%1ي"}, - -- assimilations ---easy {a="(n)(%s)([rlmnwy])", b="%1%2%3%3"} + {a="(_a)I", b="%1ي"} } digraphs = { @@ -549,12 +572,12 @@ digraphs = { -- ʾiʿrāb (end) -- initial straight double quote gives a connective ʾalif {a="^\"[uai]", b="ٱ"}, - {a="([%s%-])\"[uai]", b="%1ٱ"}, + {a="([%(%[%|%<%s%-])\"[uai]", b="%1ٱ"}, --p {a="(aW)(%s)([uai])", b="awuا%2%3"}, -- hyphen + initial alif without hamza: {a="(%-)([uai])([%^%_%.%`]?)(%a)", b="%1ا%3%4"}, - {a="^([uai])", b="ا%1"}, -- initial alif without hamza - {a="(%s)([uai])", b="%1ا"}, -- initial alif without hamza + {a="^([%(%[%|%<]?)([uai])", b="%1ا%2"}, -- initial alif without hamza --p + {a="(%s)([%(%[%|%<]?)([uai])", b="%1%2ا"}, -- initial alif without hamza --p {a="%-%-", b="ـ"}, {a="ؤؤ", b="ؤّ"}, {a="أأ", b="أّ"}, @@ -566,6 +589,7 @@ digraphs = { {a="%_t%_t", b="ثّ"}, {a="jj", b="جّ"}, {a="%^g%^g", b="جّ"}, + {a="%.h%.h", b="حّ"}, {a="xx", b="خّ"}, {a="%_h%_h", b="خّ"}, {a="dd", b="دّ"}, @@ -680,7 +704,11 @@ punctuation = { {a="%+%@%[", b="]"}, {a="%-%@%[", b="["}, {a="%.", b="."}, - {a="([^0-9])%,", b="%1،"}, + -- replaced with the next two rules to make the Arabic comma work + -- after \abraces{} +-- {a="([^0-9])%,", b="%1،"}, + {a="%,", b="،"}, + {a="([%d])%،", b="%1,"}, {a="%?", b="؟"}, {a="%;", b="؛"}, } |