aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Alessi <alessi@robertalessi.net>2016-03-03 18:25:03 +0100
committerRobert Alessi <alessi@robertalessi.net>2016-03-03 18:25:03 +0100
commitbe01b8d5cdcaba6045625a5006edf09d7f619264 (patch)
tree73a33d6a247478c73023e8064b1e5b177011200a
parent6a9a1c2f1ae4c29530069ba47316adfdf63f21fe (diff)
downloadarabluatex-be01b8d5cdcaba6045625a5006edf09d7f619264.tar.gz
šadda over hamza + improved madda
-rw-r--r--arabluatex_fullvoc.lua12
-rw-r--r--arabluatex_trans.lua43
-rw-r--r--arabluatex_voc.lua10
3 files changed, 48 insertions, 17 deletions
diff --git a/arabluatex_fullvoc.lua b/arabluatex_fullvoc.lua
index a56a33f..b0991bf 100644
--- a/arabluatex_fullvoc.lua
+++ b/arabluatex_fullvoc.lua
@@ -31,10 +31,15 @@ hamzafv = {
31 {a="w\"'", b="ؤ"}, 31 {a="w\"'", b="ؤ"},
32 {a="i\"'", b="إ"}, 32 {a="i\"'", b="إ"},
33 {a="y\"'", b="ئ"}, 33 {a="y\"'", b="ئ"},
34 -- hamza takes tašdīd too
35 {a="''([Uu])", b="ؤؤ%1"},
36 {a="''([Aa])", b="أأ%1"},
37 {a="''([Ii])", b="ئئ%1"},
34 -- initial long u 38 -- initial long u
35 {a="%'%_U", b="أU"}, 39 {a="%'%_U", b="أU"},
36 -- madda (historic writing below) 40 -- madda (historic writing below)
37 {a="'A", b="آ"}, 41 {a="'a'([^uaiUAI])", b="آ%1"},
42 {a="'a?A", b="آ"},
38 {a="(A)(')(i)$", b="aآء%3"}, 43 {a="(A)(')(i)$", b="aآء%3"},
39 {a="(A)(')(i)(%W)", b="aآء%3%4"}, 44 {a="(A)(')(i)(%W)", b="aآء%3%4"},
40 {a="(A)(')(i)", b="aآئ%3"}, -- historic madda 45 {a="(A)(')(i)", b="aآئ%3"}, -- historic madda
@@ -55,7 +60,7 @@ hamzafv = {
55-- {a="([UI])(')([uai]N?)(%W)", b="%1ء%3%4"}, 60-- {a="([UI])(')([uai]N?)(%W)", b="%1ء%3%4"},
56 -- ^say'aN and .zim'aN are special orthographies 61 -- ^say'aN and .zim'aN are special orthographies
57 {a="(%^say)(%')(aN)", b="%1ئ%3"}, 62 {a="(%^say)(%')(aN)", b="%1ئ%3"},
58 {a="(.zim)(%')(aN)", b="%1ئ%3"}, 63 {a="(.zi?m)(%')(aN)", b="%1ئ%3"},
59 {a="([^uai])(')([uai]N?)$", b="%1ء%3"}, 64 {a="([^uai])(')([uai]N?)$", b="%1ء%3"},
60 {a="([^uai])(')([uai]N?)(%W)", b="%1ء%3%4"}, 65 {a="([^uai])(')([uai]N?)(%W)", b="%1ء%3%4"},
61 -- middle 66 -- middle
@@ -124,6 +129,9 @@ digraphsfv = {
124 {a="^([uai])", b="ٱ"}, -- initial alif without hamza 129 {a="^([uai])", b="ٱ"}, -- initial alif without hamza
125 {a="(%s)([uai])", b="%1ٱ"}, -- initial alif without hamza 130 {a="(%s)([uai])", b="%1ٱ"}, -- initial alif without hamza
126 {a="%-%-", b="ـ"}, 131 {a="%-%-", b="ـ"},
132 {a="ؤؤ", b="ؤّ"},
133 {a="أأ", b="أّ"},
134 {a="ئئ", b="ئّ"},
127 {a="bb", b="بّ"}, 135 {a="bb", b="بّ"},
128 {a="BB", b="ـّ"}, 136 {a="BB", b="ـّ"},
129 {a="tt", b="تّ"}, 137 {a="tt", b="تّ"},
diff --git a/arabluatex_trans.lua b/arabluatex_trans.lua
index 4b0fca0..a178cf2 100644
--- a/arabluatex_trans.lua
+++ b/arabluatex_trans.lua
@@ -32,16 +32,21 @@ nulltr = {
32 32
33hamzatrdmg = { 33hamzatrdmg = {
34 -- hard coded hamza 34 -- hard coded hamza
35 {a="|\"'", b="'"}, 35 {a="|\"'", b="ʾ"},
36 {a="A\"'", b="'"}, 36 {a="A\"'", b="ʾ"},
37 {a="[au]\"'", b="'"}, 37 {a="[au]\"'", b="ʾ"},
38 {a="w\"'", b="'"}, 38 {a="w\"'", b="ʾ"},
39 {a="i\"'", b="'"}, 39 {a="i\"'", b="ʾ"},
40 {a="y\"'", b="'"}, 40 {a="y\"'", b="ʾ"},
41 -- hamza takes tašdīd too
42 {a="''([Uu])", b="ʾʾ%1"},
43 {a="''([Aa])", b="ʾʾ%1"},
44 {a="''([Ii])", b="ʾʾ%1"},
41 -- initial long u 45 -- initial long u
42 {a="%'%_U", b="ʾU"}, 46 {a="%'%_U", b="ʾU"},
43 -- madda (historic writing below) 47 -- madda (historic writing below)
44 {a="'A", b="ʾA"}, 48 {a="'a'([^uaiUAI])", b="ʾA%1"},
49 {a="'a?A", b="ʾA"},
45 {a="(A)(')(i)$", b="%1ʾ%3"}, 50 {a="(A)(')(i)$", b="%1ʾ%3"},
46 {a="(A)(')(i)(%W)", b="%1ʾ%3%4"}, 51 {a="(A)(')(i)(%W)", b="%1ʾ%3%4"},
47 {a="(A)(')(i)", b="%1ʾ%3"}, -- historic madda 52 {a="(A)(')(i)", b="%1ʾ%3"}, -- historic madda
@@ -192,18 +197,28 @@ shortvtrdmg = {
192 197
193hamzatrloc = { 198hamzatrloc = {
194 -- hard coded hamza 199 -- hard coded hamza
195 {a="|\"'", b="'"}, 200 {a="|\"'", b="ʾ"},
196 {a="A\"'", b="'"}, 201 {a="A\"'", b="ʾ"},
197 {a="[au]\"'", b="'"}, 202 {a="[au]\"'", b="ʾ"},
198 {a="w\"'", b="'"}, 203 {a="w\"'", b="ʾ"},
199 {a="i\"'", b="'"}, 204 {a="i\"'", b="ʾ"},
200 {a="y\"'", b="'"}, 205 {a="y\"'", b="ʾ"},
206 -- hamza takes tašdīd too
207 {a="''([Uu])", b="ʾʾ%1"},
208 {a="''([Aa])", b="ʾʾ%1"},
209 {a="''([Ii])", b="ʾʾ%1"},
201 -- initial long u 210 -- initial long u
202 {a="%'%_U", b="U"}, 211 {a="%'%_U", b="U"},
203 -- madda (historic writing below) 212 -- madda (historic writing below)
204 {a="^(')(A)", b="%2"}, 213 {a="^(')(A)", b="%2"},
205 {a="(%W)(')(A)", b="%1%3"}, 214 {a="(%W)(')(A)", b="%1%3"},
206 {a="'A", b="ʾA"}, 215
216 {a="^'a'([^uaiUAI])", b="A%1"},
217 {a="(%W)'a'([^uaiUAI])", b="%1A%2"},
218 {a="'a'([^uaiUAI])", b="A%1"},
219 {a="^'a?A", b="A"},
220 {a="(%W)'a?A", b="%1A"},
221 {a="'a?A", b="ʾA"},
207 {a="(A)(')(i)$", b="%1ʾ%3"}, 222 {a="(A)(')(i)$", b="%1ʾ%3"},
208 {a="(A)(')(i)(%W)", b="%1ʾ%3%4"}, 223 {a="(A)(')(i)(%W)", b="%1ʾ%3%4"},
209 {a="(A)(')(i)", b="%1ʾ%3"}, -- historic madda 224 {a="(A)(')(i)", b="%1ʾ%3"}, -- historic madda
diff --git a/arabluatex_voc.lua b/arabluatex_voc.lua
index 3018789..844e653 100644
--- a/arabluatex_voc.lua
+++ b/arabluatex_voc.lua
@@ -72,10 +72,15 @@ hamza = {
72 {a="w\"'", b="ؤ"}, 72 {a="w\"'", b="ؤ"},
73 {a="i\"'", b="إ"}, 73 {a="i\"'", b="إ"},
74 {a="y\"'", b="ئ"}, 74 {a="y\"'", b="ئ"},
75 -- hamza takes tašdīd too
76 {a="''([Uu])", b="ؤؤ%1"},
77 {a="''([Aa])", b="أأ%1"},
78 {a="''([Ii])", b="ئئ%1"},
75 -- initial long u 79 -- initial long u
76 {a="%'%_U", b="أU"}, 80 {a="%'%_U", b="أU"},
77 -- madda (historic writing below) 81 -- madda (historic writing below)
78 {a="'A", b="آ"}, 82 {a="'a'([^uaiUAI])", b="آ%1"},
83 {a="'a?A", b="آ"},
79 {a="(A)(')(i)$", b="aآء%3"}, 84 {a="(A)(')(i)$", b="aآء%3"},
80 {a="(A)(')(i)(%W)", b="aآء%3%4"}, 85 {a="(A)(')(i)(%W)", b="aآء%3%4"},
81 {a="(A)(')(i)", b="aآئ%3"}, -- historic madda 86 {a="(A)(')(i)", b="aآئ%3"}, -- historic madda
@@ -173,6 +178,9 @@ digraphs = {
173 {a="^([uai])", b="ا%1"}, -- initial alif without hamza 178 {a="^([uai])", b="ا%1"}, -- initial alif without hamza
174 {a="(%s)([uai])", b="%1ا%2"}, -- initial alif without hamza 179 {a="(%s)([uai])", b="%1ا%2"}, -- initial alif without hamza
175 {a="%-%-", b="ـ"}, 180 {a="%-%-", b="ـ"},
181 {a="ؤؤ", b="ؤّ"},
182 {a="أأ", b="أّ"},
183 {a="ئئ", b="ئّ"},
176 {a="bb", b="بّ"}, 184 {a="bb", b="بّ"},
177 {a="BB", b="ـّ"}, 185 {a="BB", b="ـّ"},
178 {a="tt", b="تّ"}, 186 {a="tt", b="تّ"},