Index: trunk/extensions/Narayam/sa_rules.js |
— | — | @@ -1,163 +0,0 @@ |
2 | | -/** |
3 | | - * Trasliteration regular expression rules table for Sanskrit |
4 | | - * @author Junaid P V ([[user:Junaidpv]]) |
5 | | - * @date 2010-10-12 |
6 | | - * @credits With help from Naveen Shankar |
7 | | - * License: GPLv3, CC-BY-SA 3.0 |
8 | | - */ |
9 | | - |
10 | | - // Normal rules |
11 | | -var rules = [ |
12 | | -['क्h','c','च्'], |
13 | | -['\\\\([A-Za-z\\>_~\\.0-9])','\\\\','$1'], |
14 | | - |
15 | | -['([क-ह]़?)्a', '','$1'], |
16 | | -['([क-ह]़?)्A', '','$1ा'], |
17 | | -['([क-ह]़?)a', '','$1ा'], |
18 | | -['([क-ह]़?)्i', '','$1ि'], |
19 | | -['([क-ह]़?)(्I|िi|ॆe)', '','$1ी'], |
20 | | -['([क-ह]़?)्u', '','$1ु'], |
21 | | -['([क-ह]़?)(ुu|्U|ॊo)', '','$1ू'], |
22 | | -['([क-ह]़?)्R', '','$1ृ'], |
23 | | -['([क-ह]़?)ृR', '','$1ॄ'], |
24 | | -['([क-ह]़?)्ळ्l', '','$1ॢ'], |
25 | | -['([क-ह]़?)ॢl', '','$1ॣ'], |
26 | | -['([क-ह]़?)ॆ\\^', '','$1ॅ'], |
27 | | -['([क-ह]़?)्e', '','$1ॆ'], |
28 | | -['([क-ह]़?)्E', '','$1े'], |
29 | | -['([क-ह]़?)ॊ\\^', '','$1ॉ'], |
30 | | -['([क-ह]़?)i', '','$1ै'], |
31 | | -['([क-ह]़?)्o', '','$1ॊ'], |
32 | | -['([क-ह]़?)्O', '','$1ो'], |
33 | | -['([क-ह]़?)u', '','$1ौ'], |
34 | | -['([क-ह]़?)ृa', '','$1्ऱ'], |
35 | | -['([क-ह]़?)ृA', '','$1्ऱा'], |
36 | | -['([क-ह]़?)ृi', '','$1्ऱि'], |
37 | | -['([क-ह]़?)ृI', '','$1्ऱी'], |
38 | | -['([क-ह]़?)ृu', '','$1्ऱु'], |
39 | | -['([क-ह]़?)ृU', '','$1्ऱू'], |
40 | | -['([क-ह]़?)ृ\\^', '','$1्ऱॅ'], |
41 | | -['([क-ह]़?)ृe', '','$1्ऱॆ'], |
42 | | -['([क-ह]़?)ृE', '','$1्ऱे'], |
43 | | -['([क-ह]़?)ृo', '','$1्ऱॊ'], |
44 | | -['([क-ह]़?)ृO', '','$1्ऱो'], |
45 | | -['([क-ह]़?)ृ\\~', '','$1्ऱ्'], |
46 | | -['([क-ह])्\\`', '','$1़्'], |
47 | | - |
48 | | -['अa', '','आ'], |
49 | | -['(ऒo|उu)', '','ऊ'], |
50 | | -['ऎ\\^', '','ऍ'], |
51 | | -['अi', '','ऐ'], |
52 | | -['अ\\^', '','ॲ'], |
53 | | -['(इi|ऎe)', '','ई'], |
54 | | -['ऒ\\^', '','ऑ'], |
55 | | -['अu', '','औ'], |
56 | | -['ऋR', '','ॠ'], |
57 | | -['ळ्l', '','ऌ'], |
58 | | -['ऌl', '','ॡ'], |
59 | | -['ं\\^', '','ँ'], |
60 | | -['ंm', '','ँ'], |
61 | | -['ओM', '','ॐ'], |
62 | | - |
63 | | -['क्h', '','ख्'], |
64 | | -['ग्h', '','घ्'], |
65 | | -['न्g', '','ङ्'], |
66 | | -['च्h', '','छ्'], |
67 | | -['ज्h', '','झ्'], |
68 | | -['न्j', '','ञ्'], |
69 | | -['ट्h', '','ठ्'], |
70 | | -['ड्h', '','ढ्'], |
71 | | -['त्h', '','थ्'], |
72 | | -['द्h', '','ध्'], |
73 | | -['प्h', '','फ्'], |
74 | | -['ब्h', '','भ्'], |
75 | | -['ऋa', '','ऱ'], |
76 | | -['ऋA', '','ऱा'], |
77 | | -['ऋi', '','ऱि'], |
78 | | -['ऋI', '','ऱी'], |
79 | | -['ऋu', '','ऱु'], |
80 | | -['ऋU', '','ऱू'], |
81 | | -['ऋ\\^', '','ऱॅ'], |
82 | | -['ऋe', '','ऱॆ'], |
83 | | -['ऋE', '','ऱे'], |
84 | | -['ऋo', '','ऱॊ'], |
85 | | -['ऋO', '','ऱो'], |
86 | | -['ऋ\\~', '','ऱ्'], |
87 | | - |
88 | | -['स्h', '','ष्'], |
89 | | -['क़्h', '','ख़्'], |
90 | | -['ज़्h', '','ऴ्'], |
91 | | -['।\\.', '','॥'], |
92 | | - |
93 | | -['a', '','अ'], |
94 | | -['b', '','ब्'], |
95 | | -['c', '','क्'], |
96 | | -['d', '','द्'], |
97 | | -['e', '','ऎ'], |
98 | | -['(f|F)', '','फ़्'], |
99 | | -['g', '','ग्'], |
100 | | -['h', '','ह्'], |
101 | | -['i', '','इ'], |
102 | | -['j', '','ज्'], |
103 | | -['k', '','क्'], |
104 | | -['l', '','ल्'], |
105 | | -['m', '','म्'], |
106 | | -['n', '','न्'], |
107 | | -['o', '','ऒ'], |
108 | | -['p', '','प्'], |
109 | | -['q', '','क़्'], |
110 | | -['r', '','र्'], |
111 | | -['s', '','स्'], |
112 | | -['t', '','त्'], |
113 | | -['u', '','उ'], |
114 | | -['(v|w)', '','व्'], |
115 | | -['x', '','क्ष्'], |
116 | | -['y', '','य्'], |
117 | | -['(z|Z)', '','ज़्'], |
118 | | -['A', '','आ'], |
119 | | -['B', '','ब्ब्'], |
120 | | -['C', '','क्क्'], |
121 | | -['D', '','ड्'], |
122 | | -['E', '','ए'], |
123 | | -//'F', '','फ्'], |
124 | | -['G', '','ग्ग्'], |
125 | | -['H', '','ः'], |
126 | | -['I', '','ई'], |
127 | | -['J', '','ज्ज्'], |
128 | | -['K', '','क्क्'], |
129 | | -['L', '','ळ्'], |
130 | | -['M', '','ं'], |
131 | | -['N', '','ण्'], |
132 | | -['O', '','ओ'], |
133 | | -['P', '','प्प्'], |
134 | | -//'Q', '','अ'], |
135 | | -['R', '','ऋ'], |
136 | | -['S', '','श्'], |
137 | | -['T', '','ट्'], |
138 | | -['U', '','ऊ'], |
139 | | -['(V|W)', '','व्व्'], |
140 | | -['X', '','क्ष्'], |
141 | | -['Y', '','य्य्'], |
142 | | -//'z', '','अ' |
143 | | -['0', '','०'], |
144 | | -['1', '','१'], |
145 | | -['2', '','२'], |
146 | | -['3', '','३'], |
147 | | -['4', '','४'], |
148 | | -['5', '','५'], |
149 | | -['6', '','६'], |
150 | | -['7', '','७'], |
151 | | -['8', '','८'], |
152 | | -['9', '','९'], |
153 | | -['~', '','्'], |
154 | | -['\\.', '','।'], |
155 | | -['//', '','ऽ'], |
156 | | -['\\`', '','़'] |
157 | | -]; |
158 | | - |
159 | | -jQuery.narayam.addScheme( 'sa', { |
160 | | - 'namemsg': 'narayam-sa', |
161 | | - 'extended_keyboard': false, |
162 | | - 'lookbackLength': 2, |
163 | | - 'rules': rules |
164 | | -} ); |
Index: trunk/extensions/Narayam/ta_rules.js |
— | — | @@ -1,110 +0,0 @@ |
2 | | -/** |
3 | | - * Trasliteration regular expression rules table for Tamil |
4 | | - * @author Junaid P V ([[user:Junaidpv]]) |
5 | | - * @date 2010-11-21 |
6 | | - * License: GPLv3, CC-BY-SA 3.0 |
7 | | - */ |
8 | | - |
9 | | -// Normal rules |
10 | | -var rules = [ |
11 | | -['ச்h','h','ச்ஹ்',], |
12 | | -['ழ்h','h','ழ்ஹ்',], |
13 | | - |
14 | | - //'(ஸ்ரிi|ஸ்ர்I)', '','', |
15 | | - |
16 | | -['([க-ஹ])்a', '','$1'], |
17 | | -['([க-ஹ])(்A|a)', '','$1ா'], |
18 | | -['([க-ஹ])்i', '','$1ி'], |
19 | | -['([க-ஹ])(்I|ிi)', '','$1ீ'], |
20 | | -['([க-ஹ])்u', '','$1ு'], |
21 | | -['([க-ஹ])(்U|ுu)', '','$1ூ'], |
22 | | -['([க-ஹ])்e', '','$1ெ'], |
23 | | -['([க-ஹ])(்E|ெe)', '','$1ே'], |
24 | | -['([க-ஹ])i', '','$1ை'], |
25 | | -['([க-ஹ])்o', '','$1ொ'], |
26 | | -['([க-ஹ])(்O|ொo)', '','$1ோ'], |
27 | | -['([க-ஹ])u', '','$1ௌ'], |
28 | | - |
29 | | -['([அ-ஹ][ெ-்]?)n', '','$1ன்'], |
30 | | - |
31 | | -['அa', '','ஆ'], |
32 | | -['இi', '','ஈ'], |
33 | | -['உu', '','ஊ'], |
34 | | -['எe', '','ஏ'], |
35 | | -['அi', '','ஐ'], |
36 | | -['ஒo', '','ஓ'], |
37 | | -['அu', '','ஔ'], |
38 | | - |
39 | | -['(ந்|ன்)g', '','ங்'], |
40 | | -['(ந்|ன்)j', '','ஞ்'], |
41 | | -['ச்h', '','ச்'], |
42 | | -['ழ்h', '','ழ்'], |
43 | | -['ட்h', '','த்'], |
44 | | -['ஸ்h', '','ஷ்'], |
45 | | - |
46 | | -['a', '','அ'], |
47 | | -['c', '','ச்'], |
48 | | -['d', '','ட்'], |
49 | | -['e', '','எ'], |
50 | | -['h', '','ஹ்'], |
51 | | -['i', '','இ'], |
52 | | -['j', '','ஜ்'], |
53 | | -['k', '','க்'], |
54 | | -['l', '','ல்'], |
55 | | -['m', '','ம்'], |
56 | | -['n', '','ந்'], |
57 | | -['o', '','ஒ'], |
58 | | -['p', '','ப்'], |
59 | | -['q', '','ஃ'], |
60 | | -['r', '','ர்'], |
61 | | -['s', '','ச்'], |
62 | | -['t', '','ட்'], |
63 | | -['u', '','உ'], |
64 | | -['v', '','வ்'], |
65 | | -['w', '','ந்'], |
66 | | -['y', '','ய்'], |
67 | | -['z', '','ழ்'], |
68 | | -['A', '','ஆ'], |
69 | | - |
70 | | -['C', '','க்க்'], |
71 | | -['E', '','ஏ'], |
72 | | -['H', '','ஃ'], |
73 | | -['I', '','ஈ'], |
74 | | -['J', '','ஜ்ஜ்'], |
75 | | -['K', '','க்'], |
76 | | -['L', '','ள்'], |
77 | | -['M', '','ம்ம்'], |
78 | | -['N', '','ண்'], |
79 | | -['O', '','ஓ'], |
80 | | -['P', '','ப்ப்'], |
81 | | -['R', '','ற்'], |
82 | | -['S', '','ஸ்'], |
83 | | -['T', '','ட்'], |
84 | | -['U', '','ஊ'], |
85 | | -['(V|W)', '','வ்வ்'], |
86 | | -['Y', '','ய்ய்'], |
87 | | -['Z', '','ஶ்'], |
88 | | - |
89 | | -['~', '','்'], |
90 | | - |
91 | | -['\\\\0', '','\u0be6'], |
92 | | -['\\\\1', '','௧'], |
93 | | -['\\\\2', '','௨'], |
94 | | -['\\\\3', '','௩'], |
95 | | -['\\\\4', '','௪'], |
96 | | -['\\\\5', '','௫'], |
97 | | -['\\\\6', '','௬'], |
98 | | -['\\\\7', '','௭'], |
99 | | -['\\\\8', '','௮'], |
100 | | -['\\\\9', '','௯'], |
101 | | -['10\\\\', '','\u0BF0'], |
102 | | -['100\\\\', '','\u0BF1'], |
103 | | -['1000\\\\', '','\u0BF2'] |
104 | | -]; |
105 | | - |
106 | | -jQuery.narayam.addScheme( 'ta', { |
107 | | - 'namemsg': 'narayam-ta', |
108 | | - 'extended_keyboard': false, |
109 | | - 'lookbackLength': 1, |
110 | | - 'rules': rules |
111 | | -} ); |
Index: trunk/extensions/Narayam/ml_rules.js |
— | — | @@ -1,335 +0,0 @@ |
2 | | -/** |
3 | | - * Trasliteration regular expression rules table for Malayalam |
4 | | - * @author Junaid P V ([[user:Junaidpv]]) with extensive advise from Thachan Makan ([[user:Thachan.makan]]) |
5 | | - * @date 2010-05-19 (update: 2010-12-11) |
6 | | - * @credits Malayalam Wikimedia Community, especialy Thachan Makan ([[user:Thachan.makan]]) |
7 | | - * License: GPLv3, CC-BY-SA 3.0 |
8 | | - */ |
9 | | - |
10 | | -// Normal rules |
11 | | -var rules = [ |
12 | | -['(\u200c)+a', '', 'അ'], |
13 | | -['(\u200c)+A', '', 'ആ'], |
14 | | -['(\u200c)+i', '', 'ഇ'], |
15 | | -['(\u200c)+u', '', 'ഉ'], |
16 | | -['(\u200c)+U', '', 'ഊ'], |
17 | | -['(\u200c)+R', '', 'ഋ'], |
18 | | -['(\u200c)+e', '', 'എ'], |
19 | | -['(\u200c)+E', '', 'ഏ'], |
20 | | -['(\u200c)+I', '', 'ഐ'], |
21 | | -['(\u200c)+o', '', 'ഒ'], |
22 | | -['(\u200c)+O', '', 'ഓ'], |
23 | | -['(\u200c)+H', '', 'ഃ'], |
24 | | -['ൻൿh','nc','ഞ്ച്'], |
25 | | -['ൿh','c', 'ച്'], |
26 | | -['ക്ക്h','cc', 'ച്ച്'], |
27 | | -['ല്പ്p','lp','ൽപ്പ്'], |
28 | | - |
29 | | -['\\\\([A-Za-z\\>_~])','\\\\','$1'], |
30 | | - |
31 | | -['([ക-ഹ])്R', '', '$1ൃ'], |
32 | | -['ന്ന്j', '', 'ഞ്ഞ്'], |
33 | | -['ന്ന്g', '', 'ങ്ങ്'], |
34 | | -['റ്റ്h', '', 'ത്'], |
35 | | -['റ്റ്t', '', 'ട്ട്'], |
36 | | -['ന്റ്h', '', 'ന്ത്'], |
37 | | -['([ക-ഹ])്ല്l', 'L', '$1\u0d62'], |
38 | | -['([ക-ഹ])\u0d62l', '', '$1\u0d63'], |
39 | | -['([അ-ഊഌഎ-ഐഒ-ഹ])([ഽ-ൂെ-ൌൗ])+R', '', '$1$2റ്'], |
40 | | -['([ക-ഹ])ൃa', '', '$1്ര'], |
41 | | -['([ക-ഹ])ൃA', '', '$1്രാ'], |
42 | | -['([ക-ഹ])ൃi', '', '$1്രി'], |
43 | | -['([ക-ഹ])ൃI', '', '$1്രീ'], |
44 | | -['([ക-ഹ])ൃu', '', '$1്രു'], |
45 | | -['([ക-ഹ])ൃU', '', '$1്രൂ'], |
46 | | -['([ക-ഹ])ൃe', '', '$1്രെ'], |
47 | | -['([ക-ഹ])ൃE', '', '$1്രേ'], |
48 | | -['([ക-ഹ])ൃo', '', '$1്രൊ'], |
49 | | -['([ക-ഹ])ൃO', '', '$1്രോ'], |
50 | | -['([ക-ഹ])്(l|L)', '', '$1്ല്'], |
51 | | -['അa', '', 'ആ'], |
52 | | -['അi', '', 'ഐ'], |
53 | | -['അu', '', 'ഔ'], |
54 | | -['ഇi', '', 'ഈ'], |
55 | | -['ഉu', '', 'ഊ'], |
56 | | -['ഊo', '', 'ഊഊ'], |
57 | | -['ഋR', '', 'ൠ'], |
58 | | -['ഋa', '', 'റ'], |
59 | | -['ഋA', '', 'റാ'], |
60 | | -['ഋi', '', 'റി'], |
61 | | -['ഋI', '', 'റീ'], |
62 | | -['ഋu', '', 'റു'], |
63 | | -['ഋU', '', 'റൂ'], |
64 | | -['ഋe', '', 'റെ'], |
65 | | -['ഋE', '', 'റേ'], |
66 | | -['ഋo', '', 'റൊ'], |
67 | | -['ഋO', '', 'റോ'], |
68 | | -['ഋ~', '', 'റ്'], |
69 | | -['ഌl', '', 'ൡ'], |
70 | | -['എe', '', 'ഈ'], |
71 | | -['ഒo', '', 'ഊ'], |
72 | | -['ാa', '', 'ാാ'], |
73 | | -['ീi', '', 'ീീ'], |
74 | | -['ൂu', '', 'ൂൂ'], |
75 | | -['ൂo', '', 'ൂൂ'], |
76 | | -['ൄR', '', 'ൄൄ'], |
77 | | -['േE', '', 'േേ'], |
78 | | -['ോO', '', 'ോോ'], |
79 | | -['ൗu', '', 'ൗൗ'], |
80 | | -['\u0d62\\^', '', '\u0d63'], |
81 | | -['\u0d63\\^', '', '\u0d63\u0d63'], |
82 | | -['ക്h', '', 'ഖ്'], |
83 | | -['ഗ്h', '', 'ഘ്'], |
84 | | -['ൻg', '', 'ങ്'], |
85 | | -['ച്h', '', 'ഛ്'], |
86 | | -['ജ്h', '', 'ഝ്'], |
87 | | -['ട്h', '', 'ഠ്'], |
88 | | -['ഡ്h', '', 'ഢ്'], |
89 | | -['ത്h', '', 'ഥ്'], |
90 | | -['ദ്h', '', 'ധ്'], |
91 | | -['പ്h', '', 'ഫ്'], |
92 | | -['ബ്h', '', 'ഭ്'], |
93 | | -['ംa', '', 'മ'], |
94 | | -['ംA', '', 'മാ'], |
95 | | -['ംi', '', 'മി'], |
96 | | -['ംI', '', 'മീ'], |
97 | | -['ംu', '', 'മു'], |
98 | | -['ംU', '', 'മൂ'], |
99 | | -['ംR', '', 'മൃ'], |
100 | | -['ംe', '', 'മെ'], |
101 | | -['ംE', '', 'മേ'], |
102 | | -['ംo', '', 'മൊ'], |
103 | | -['ംO', '', 'മോ'], |
104 | | -['ംm', '', 'മ്മ്'], |
105 | | -['([^സ])ംr', '', '$1മ്ര്'], |
106 | | -['ംp', '', 'മ്പ്'], |
107 | | -['([^സ])ം(l|L)', '', '$1മ്ല്'], |
108 | | -['ം~', '', 'മ്'], |
109 | | -['([^സ])ംn', '', '$1മ്ന്'], |
110 | | -['([^സ])ംy', '', '$1മ്യ്'], |
111 | | -['സ്h', '', 'ഷ്'], |
112 | | -['ശ്h', '', 'ഴ്'], |
113 | | -['ൺ\\\\\\\\', '', 'ണ്\u200d'], // old style chillu N |
114 | | -['ൺ~', '', 'ണ്'], |
115 | | -['ൺR', '', 'ണൃ'], |
116 | | -['ൺN', '', 'ണ്ണ്'], |
117 | | -['ൺT', '', 'ണ്ട്'], |
118 | | -['ൺD', '', 'ണ്ഡ്'], |
119 | | -['ൺy', '', 'ണ്യ്'], |
120 | | -['ൺv', '', 'ണ്വ്'], |
121 | | -['ൺm', '', 'ണ്മ്'], |
122 | | -['ൻ\\\\\\\\', '', 'ന്\u200d'], // old style chillu n |
123 | | -['ൻ~', '', 'ന്'], |
124 | | -['ൻr', '', 'ന്ര്'], |
125 | | -['ൻR', '', 'നൃ'], |
126 | | -['ൻk', '', 'ങ്ക്'], |
127 | | -['ൻj', '', 'ഞ്'], |
128 | | -['ൻn', '', 'ന്ന്'], |
129 | | -['ൻd', '', 'ന്ദ്'], |
130 | | -['ൻt', '', 'ന്റ്'], |
131 | | -['ൻm', '', 'ന്മ്'], |
132 | | -['ൻL', '', 'ന്ല്'], |
133 | | -['ൻv', '', 'ന്വ്'], |
134 | | -['ൻy', '', 'ന്യ്'], |
135 | | -['ർ\\\\\\\\', '', 'ര്\u200d'], // old style chill r |
136 | | -['ർ~', '', 'ര്'], |
137 | | -['ർr', '', 'റ്'], |
138 | | -['ർR', '', 'രൃ'], |
139 | | -['ർy', '', 'ര്യ്'], |
140 | | -['ൽ\\\\\\\\', '', 'ല്\u200d'], // old style chillu l |
141 | | -['ൽ~', '', 'ല്'], |
142 | | -['ൽR', '', 'ലൃ'], |
143 | | -['ൽ(l|L)', '', 'ല്ല്'], |
144 | | -['ൽp', '', 'ല്പ്'], |
145 | | -['ൽy', '', 'ല്യ്'], |
146 | | -['ൽv', '', 'ല്വ്'], |
147 | | -['ൾ\\\\\\\\', '', 'ള്\u200d'], // old style chillu L |
148 | | -['ൾ~', '', 'ള്'], |
149 | | -['ൾR', '', 'ളൃ'], |
150 | | -['ൾL', '', 'ള്ള്'], |
151 | | -['ൾy', '', 'ള്യ്'], |
152 | | -['ൾl', '', 'ഌ'], |
153 | | -['ൿ\\\\\\\\', '', 'ക്\u200d'], // old style chillu k |
154 | | -['ൿR', '', 'കൃ'], |
155 | | -['ൿy', '', 'ക്യ്'], |
156 | | -['ൿ(l|L)', '', 'ക്ല്'], |
157 | | -['ൿv', '', 'ക്വ്'], |
158 | | -['ൿ(k|c)', '', 'ക്ക്'], |
159 | | -['([ക-ഹ])a', '', '$1ാ'], |
160 | | -['([ക-ഹ])്a', '', '$1'], |
161 | | -['ൺa', '', 'ണ'], |
162 | | -['ൻa', '', 'ന'], |
163 | | -['ർa', '', 'ര'], |
164 | | -['ൽa', '', 'ല'], |
165 | | -['ൾa', '', 'ള'], |
166 | | -['ൿa', '', 'ക'], |
167 | | -['([ക-ഹ])്A', '', '$1ാ'], |
168 | | -['ൺA', '', 'ണാ'], |
169 | | -['ൻA', '', 'നാ'], |
170 | | -['ർA', '', 'രാ'], |
171 | | -['ൽA', '', 'ലാ'], |
172 | | -['ൾA', '', 'ളാ'], |
173 | | -['ൿA', '', 'കാ'], |
174 | | -['([ക-ഹ])്i', '', '$1ി'], |
175 | | -['ൺi', '', 'ണി'], |
176 | | -['ൻi', '', 'നി'], |
177 | | -['ർi', '', 'രി'], |
178 | | -['ൽi', '', 'ലി'], |
179 | | -['ൾi', '', 'ളി'], |
180 | | -['ൿi', '', 'കി'], |
181 | | -['([ക-ഹ])്I', '', '$1ീ'], |
182 | | -['ൺI', '', 'ണീ'], |
183 | | -['ൻI', '', 'നീ'], |
184 | | -['ർI', '', 'രീ'], |
185 | | -['ൽI', '', 'ലീ'], |
186 | | -['ൾI', '', 'ളീ'], |
187 | | -['ൿI', '', 'കീ'], |
188 | | -['([ക-ഹ])ിi', '', '$1ീ'], |
189 | | -['([ക-ഹ])െe', '', '$1ീ'], |
190 | | -['([ക-ഹ])്u', '', '$1ു'], |
191 | | -['ൺu', '', 'ണു'], |
192 | | -['ൻu', '', 'നു'], |
193 | | -['ർu', '', 'രു'], |
194 | | -['ൽu', '', 'ലു'], |
195 | | -['ൾu', '', 'ളു'], |
196 | | -['ൿu', '', 'കു'], |
197 | | -['([ക-ഹ])്U', '', '$1ൂ'], |
198 | | -['([ക-ഹ])ുu', '', '$1ൂ'], |
199 | | -['ൺU', '', 'ണൂ'], |
200 | | -['ൻU', '', 'നൂ'], |
201 | | -['ർU', '', 'രൂ'], |
202 | | -['ൽU', '', 'ലൂ'], |
203 | | -['ൾU', '', 'ളൂ'], |
204 | | -['ൿU', '', 'കൂ'], |
205 | | -['([ക-ഹ])ൊo', '', '$1ൂ'], |
206 | | -['([ക-ഹ])ൃR', '', '$1ൄ'], |
207 | | -['([ക-ഹ])്e', '', '$1െ'], |
208 | | -['ൺe', '', 'ണെ'], |
209 | | -['ൻe', '', 'നെ'], |
210 | | -['ർe', '', 'രെ'], |
211 | | -['ൽe', '', 'ലെ'], |
212 | | -['ൾe', '', 'ളെ'], |
213 | | -['ൿe', '', 'കെ'], |
214 | | -['([ക-ഹ])്E', '', '$1േ'], |
215 | | -['ൺE', '', 'ണേ'], |
216 | | -['ൻE', '', 'നേ'], |
217 | | -['ർE', '', 'രേ'], |
218 | | -['ൽE', '', 'ലേ'], |
219 | | -['ൾE', '', 'ളേ'], |
220 | | -['ൿE', '', 'കേ'], |
221 | | -['([ക-ഹ])i', '', '$1ൈ'], |
222 | | -['([ക-ഹ])്o', '', '$1ൊ'], |
223 | | -['ൺo', '', 'ണൊ'], |
224 | | -['ൻo', '', 'നൊ'], |
225 | | -['ർo', '', 'രൊ'], |
226 | | -['ൽo', '', 'ലൊ'], |
227 | | -['ൾo', '', 'ളൊ'], |
228 | | -['ൿo', '', 'കൊ'], |
229 | | -['([ക-ഹ])്O', '', '$1ോ'], |
230 | | -['ൺO', '', 'ണോ'], |
231 | | -['ൻO', '', 'നോ'], |
232 | | -['ർO', '', 'രോ'], |
233 | | -['ൽO', '', 'ലോ'], |
234 | | -['ൾO', '', 'ളോ'], |
235 | | -['ൿO', '', 'കോ'], |
236 | | -['([ക-ഹ])u', '', '$1ൗ'], |
237 | | -['([ക-ഹ])U', '', '$1ൌ'], |
238 | | -['([അ-്])m', '', '$1ം'], |
239 | | -['\\\\0', '', '൦'], // escape to ml digit 0 by \0 |
240 | | -['\\\\1', '', '൧'], // escape to ml digit 1 by \1 |
241 | | -['\\\\2', '', '൨'], // escape to ml digit 2 by \2 |
242 | | -['\\\\3', '', '൩'], // escape to ml digit 3 by \3 |
243 | | -['\\\\4', '', '൪'], // escape to ml digit 4 by \4 |
244 | | -['\\\\5', '', '൫'], // escape to ml digit 5 by \5 |
245 | | -['\\\\6', '', '൬'], // escape to ml digit 6 by \6 |
246 | | -['\\\\7', '', '൭'], // escape to ml digit 7 by \7 |
247 | | -['\\\\8', '', '൮'], // escape to ml digit 8 by \8 |
248 | | -['\\\\9', '', '൯'], // escape to ml digit 9 by \9 |
249 | | -['മ്\\\\', '', 'ം'], |
250 | | -['ആ\\\\', '', 'ാ'], |
251 | | -['ഇ\\\\', '', 'ി'], |
252 | | -['ഈ\\\\', '', 'ീ'], |
253 | | -['ഉ\\\\', '', 'ു'], |
254 | | -['ഊ\\\\', '', 'ൂ'], |
255 | | -['ഋ\\\\', '', 'ൃ'], |
256 | | -['ൠ\\\\', '', 'ൄ'], |
257 | | -['എ\\\\', '', 'െ'], |
258 | | -['ഏ\\\\', '', 'േ'], |
259 | | -['ഐ\\\\', '', 'ൈ'], |
260 | | -['ഒ\\\\', '', 'ൊ'], |
261 | | -['ഓ\\\\', '', 'ോ'], |
262 | | -['ഔ\\\\', '', 'ൗ'], |
263 | | -['ൗ\\\\', '', 'ൌ'], |
264 | | -['ഌ\\\\', '', 'ൢ'], |
265 | | -['ൡ\\\\', '', 'ൣ'], |
266 | | -['(([ൺ-ൿം])\u200c+)?A', '', '$2ആ'], |
267 | | -['(([ൺ-ൿം])\u200c+)?B', '', '$2ബ്ബ്'], |
268 | | -['(([ൺ-ൿം])\u200c+)?C', '', '$2ച്ച്'], |
269 | | -['(([ൺ-ൿം])\u200c+)?D', '', '$2ഡ്'], |
270 | | -['(([ൺ-ൿം])\u200c+)?E', '', '$2ഏ'], |
271 | | -['(([ൺ-ൿം])\u200c+)?F', '', '$2ഫ്'], |
272 | | -['(([ൺ-ൿം])\u200c+)?G', '', '$2ഗ്ഗ്'], |
273 | | -['(([ൺ-ൿം])\u200c+)?H', '', '$2ഃ'], |
274 | | -['(([ൺ-ൿം])\u200c+)?I', '', '$2ഐ'], |
275 | | -['(([ൺ-ൿം])\u200c+)?J', '', '$2ജ്ജ്'], |
276 | | -['(([ൺ-ൿം])\u200c+)?K', '', '$2ക്ക്'], |
277 | | -['(([ൺ-ൿം])\u200c+)?L', '', '$2ൾ'], |
278 | | -['(([ൺ-ൿം])\u200c+)?M', '', '$2മ്മ്'], |
279 | | -['(([ൺ-ൿം])\u200c+)?N', '', '$2ൺ'], |
280 | | -['(([ൺ-ൿം])\u200c+)?O', '', '$2ഓ'], |
281 | | -['(([ൺ-ൿം])\u200c+)?P', '', '$2പ്പ്'], |
282 | | -['(([ൺ-ൿം])\u200c+)?Q', '', '$2ക്യ്'], |
283 | | -['(([ൺ-ൿം])\u200c+)?R', '', '$2ഋ'], |
284 | | -['(([ൺ-ൿം])\u200c+)?(S|z)', '', '$2ശ്'], |
285 | | -['(([ൺ-ൿം])\u200c+)?T', '', '$2ട്'], |
286 | | -['(([ൺ-ൿം])\u200c+)?U', '', '$2ഊ'], |
287 | | -['(([ൺ-ൿം])\u200c+)?(V|W)', '', '$2വ്വ്'], |
288 | | -['(([ൺ-ൿം])\u200c+)?X', '', '$2ക്ഷ്'], |
289 | | -['(([ൺ-ൿം])\u200c+)?Y', '', '$2യ്യ്'], |
290 | | -['(([ൺ-ൿം])\u200c+)?Z', '', '$2ശ്ശ്'], |
291 | | -['(([ൺ-ൿം])\u200c+)?a', '', '$2അ'], |
292 | | -['(([ൺ-ൿം])\u200c+)?b', '', '$2ബ്'], |
293 | | -['(([ൺ-ൿം])\u200c+)?c', '', '$2ൿ'], |
294 | | -['(([ൺ-ൿം])\u200c+)?d', '', '$2ദ്'], |
295 | | -['(([ൺ-ൿം])\u200c+)?e', '', '$2എ'], |
296 | | -['(([ൺ-ൿം])\u200c+)?f', '', '$2ഫ്'], |
297 | | -['(([ൺ-ൿം])\u200c+)?g', '', '$2ഗ്'], |
298 | | -['(([ൺ-ൿം])\u200c+)?h', '', '$2ഹ്'], |
299 | | -['(([ൺ-ൿം])\u200c+)?i', '', '$2ഇ'], |
300 | | -['(([ൺ-ൿം])\u200c+)?j', '', '$2ജ്'], |
301 | | -['(([ൺ-ൿം])\u200c+)?k', '', '$2ക്'], |
302 | | -['(([ൺ-ൿം])\u200c+)?l', '', '$2ൽ'], |
303 | | -['(([ൺ-ൿം])\u200c+)?m', '', '$2മ്'], |
304 | | -['(([ൺ-ൿം])\u200c+)?n', '', '$2ൻ'], |
305 | | -['(([ൺ-ൿം])\u200c+)?o', '', '$2ഒ'], |
306 | | -['(([ൺ-ൿം])\u200c+)?p', '', '$2പ്'], |
307 | | -['(([ൺ-ൿം])\u200c+)?q', '', '$2ക്ക്'], |
308 | | -['(([ൺ-ൿം])\u200c+)?r', '', '$2ർ'], |
309 | | -['(([ൺ-ൿം])\u200c+)?s', '', '$2സ്'], |
310 | | -['(([ൺ-ൿം])\u200c+)?t', '', '$2റ്റ്'], // tta according to 5.1 |
311 | | -['(([ൺ-ൿം])\u200c+)?u', '', '$2ഉ'], |
312 | | -['(([ൺ-ൿം])\u200c+)?(v|w)', '', '$2വ്'], |
313 | | -['(([ൺ-ൿം])\u200c+)?x', '', '$2ക്ഷ്'], |
314 | | -['(([ൺ-ൿം])\u200c+)?y', '', '$2യ്'], |
315 | | -['(([ൺ-ൿം])\u200c+)?~', '', '$2്'], |
316 | | -['(\u200C)*_', '', '\u200c'], |
317 | | -['//', '', 'ऽ'], |
318 | | -['1/4\\\\', '', '൳'], |
319 | | -['1/2\\\\', '', '൴'], |
320 | | -['3/4\\\\', '', '൵'], |
321 | | -['10\\\\', '', '\u0D70'], |
322 | | -['100\\\\', '', '\u0D71'], |
323 | | -['1000\\\\', '', '\u0D72'], |
324 | | -['\\-\\-\\-\\\\', '', '—'], // em dash |
325 | | -['\\-\\-\\\\', '', '–'], // en dash |
326 | | -['\\\\\\-', '', '−'], |
327 | | -['\\\\\\*', '', '×'], |
328 | | -['\\\\/', '', '÷'] |
329 | | -]; |
330 | | - |
331 | | -jQuery.narayam.addScheme( 'ml', { |
332 | | - 'namemsg': 'narayam-ml', |
333 | | - 'extended_keyboard': false, |
334 | | - 'lookbackLength': 2, |
335 | | - 'rules': rules |
336 | | -} ); |
Index: trunk/extensions/Narayam/bn_inscript_rules.js |
— | — | @@ -1,126 +0,0 @@ |
2 | | -/** |
3 | | - * InScript regular expression rules table for Bengali script |
4 | | - * According to CDAC's "Enhanced InScript Keyboard Layout 5.2" |
5 | | - * @author Junaid P V ([[user:Junaidpv]]) |
6 | | - * @date 2010-12-12 |
7 | | - * License: GPLv3, CC-BY-SA 3.0 |
8 | | - */ |
9 | | - |
10 | | -// Normal rules |
11 | | -var rules = [ |
12 | | -['X', '', 'ঁ'], |
13 | | -['x', '', 'ং'], |
14 | | -['_', '', 'ঃ'], |
15 | | -['D', '', 'অ'], |
16 | | -['E', '', 'আ'], |
17 | | -['F', '', 'ই'], |
18 | | -['R', '', 'ঈ'], |
19 | | -['G', '', 'উ'], |
20 | | -['T', '', 'ঊ'], |
21 | | -['\\+', '', 'ঋ'], |
22 | | -['S', '', 'এ'], |
23 | | -['W', '', 'ঐ'], |
24 | | -['A', '', 'ও'], |
25 | | -['Q', '', 'ঔ'], |
26 | | -['k', '', 'ক'], |
27 | | -['K', '', 'খ'], |
28 | | -['i', '', 'গ'], |
29 | | -['I', '', 'ঘ'], |
30 | | -['U', '', 'ঙ'], |
31 | | -[';', '', 'চ'], |
32 | | -['\\:', '', 'ছ'], |
33 | | -['p', '', 'জ'], |
34 | | -['P', '', 'ঝ'], |
35 | | -['\\}', '', 'ঞ'], |
36 | | -["'", '', 'ট'], |
37 | | -['"', '', 'ঠ'], |
38 | | -['\\[', '', 'ড'], |
39 | | -['\\{', '', 'ঢ'], |
40 | | -['C', '', 'ণ'], |
41 | | -['l', '', 'ত'], |
42 | | -['L', '', 'থ'], |
43 | | -['o', '', 'দ'], |
44 | | -['O', '', 'ধ'], |
45 | | -['v', '', 'ন'], |
46 | | -['h', '', 'প'], |
47 | | -['H', '', 'ফ'], |
48 | | -['y', '', 'ব'], |
49 | | -['Y', '', 'ভ'], |
50 | | -['c', '', 'ম'], |
51 | | -['\\?', '', 'য'], |
52 | | -['j', '', 'র'], |
53 | | -['J', '', 'ৎ'], |
54 | | -['n', '', 'ল'], |
55 | | -['M', '', 'শ'], |
56 | | -['\\<', '', 'ষ'], |
57 | | -['m', '', 'স'], |
58 | | -['u', '', 'হ'], |
59 | | -['\\]', '', '়'], |
60 | | -['e', '', 'া'], |
61 | | -['f', '', 'ি'], |
62 | | -['r', '', 'ী'], |
63 | | -['g', '', 'ু'], |
64 | | -['t', '', 'ূ'], |
65 | | -['\\=', '', 'ৃ'], |
66 | | -['s', '', 'ে'], |
67 | | -['w', '', 'ৈ'], |
68 | | -['a', '', 'ো'], |
69 | | -['q', '', 'ৌ'], |
70 | | -['d', '', '্'], |
71 | | -['/', '', 'য়'], |
72 | | -['\\>', '', ''], |
73 | | -['0', '', '০'], |
74 | | -['1', '', '১'], |
75 | | -['2', '', '২'], |
76 | | -['3', '', '৩'], |
77 | | -['4', '', '৪'], |
78 | | -['5', '', '৫'], |
79 | | -['6', '', '৬'], |
80 | | -['7', '', '৭'], |
81 | | -['8', '', '৮'], |
82 | | -['9', '', '৯'], |
83 | | -['z', '', 'ʼ'], |
84 | | -['\\!', '', 'অ্যা'], |
85 | | -['\\#', '', '্র'], |
86 | | -['\\$', '', 'র্'], |
87 | | -['\\%', '', 'জ্ঞ'], |
88 | | -['\\^', '', 'ত্র'], |
89 | | -['\\&', '', 'ক্ষ'], |
90 | | -['\\*', '', 'শ্র'], |
91 | | -['\\(', '', '\u200D'], |
92 | | -['\\)', '', '\u200C'] |
93 | | -]; |
94 | | - |
95 | | -// Extended layout for InScript. Works in Firefox only |
96 | | -var rules_x = [ |
97 | | -['F', '', 'ঌ'], |
98 | | -['\\>', '', 'ঽ'], |
99 | | -['\\=', '', 'ৠ'], |
100 | | -['l', '', 'ৎ'], |
101 | | -['\\[', '', 'ড়'], |
102 | | -['\\{', '', 'ঢ়'], |
103 | | -['\\+', '', 'ৠ'], |
104 | | -['R', '', 'ৡ'], |
105 | | -['f', '', 'ৢ'], |
106 | | -['r', '', 'ৣ'], |
107 | | -['\\.', '', ''], |
108 | | -['x', '', '৺'], |
109 | | -['\\<', '', '৲'], |
110 | | -[',', '', '৳'], |
111 | | -['\\!', '', '৴'], |
112 | | -['\\@', '', '৵'], |
113 | | -['\\#', '', '৶'], |
114 | | -['\\$', '', '৷'], |
115 | | -['\\%', '', '৸'], |
116 | | -['\\^', '', '৹'], |
117 | | -['\\?', '', '৻'], |
118 | | -['4', '', '₹'] |
119 | | -]; |
120 | | - |
121 | | -jQuery.narayam.addScheme( 'bn-inscript', { |
122 | | - 'namemsg': 'narayam-bn-inscript', |
123 | | - 'extended_keyboard': true, |
124 | | - 'lookbackLength': 0, |
125 | | - 'rules': rules, |
126 | | - 'rules_x': rules_x |
127 | | -} ); |
Index: trunk/extensions/Narayam/Narayam.js |
— | — | @@ -1,335 +0,0 @@ |
2 | | -/** |
3 | | - * Narayam |
4 | | - * Input field rewriter tool for web pages |
5 | | - * @author Junaid P V ([[user:Junaidpv]])(http://junaidpv.in) |
6 | | - * @date 2010-12-18 (Based on naaraayam transliteration tool I first wrote on 2010-05-19) |
7 | | - * @version 3.0 |
8 | | - * Last update: 2010-11-28 |
9 | | - * License: GPLv3, CC-BY-SA 3.0 |
10 | | - */ |
11 | | - |
12 | | -( function( $ ) { |
13 | | -$.narayam = new ( function() { |
14 | | - /* Private members */ |
15 | | - |
16 | | - // Reference to this object |
17 | | - var that = this; |
18 | | - // jQuery array holding all text inputs Narayam applies to |
19 | | - var $inputs = $( [] ); |
20 | | - // Input method dropdown |
21 | | - var $select = $( [] ); |
22 | | - // Whether Narayam is enabled |
23 | | - var enabled = false; |
24 | | - // Registered schemes |
25 | | - var schemes = {}; |
26 | | - // List of scheme names, ordered for presentation purposes |
27 | | - // Schemes not in this list won't be allowed to register |
28 | | - // This object is formatted as { 'schemename': '', 'schemename2': '', ... } |
29 | | - // for easy searching |
30 | | - var availableSchemes = mw.config.get( 'wgNarayamAvailableSchemes' ) || {}; |
31 | | - // Currently selected scheme |
32 | | - var currentScheme = null; |
33 | | - // Shortcut key |
34 | | - var shortcutKey = mw.config.get( 'wgNarayamShortcutKey' ) || { |
35 | | - altKey: false, |
36 | | - ctrlKey: false, |
37 | | - shiftKey: false, |
38 | | - key: null |
39 | | - }; |
40 | | - |
41 | | - /* Private functions */ |
42 | | - |
43 | | - /** |
44 | | - * Transliterate a string using the current scheme |
45 | | - * @param str String to transliterate |
46 | | - * @param lookback The lookback buffer |
47 | | - * @param useExtended Whether to use the extended part of the scheme |
48 | | - * @return Transliterated string, or str if no applicable transliteration found. |
49 | | - */ |
50 | | - function transliterate( str, lookback, useExtended ) { |
51 | | - var rules = currentScheme.extended_keyboard && useExtended ? |
52 | | - currentScheme.rules_x : currentScheme.rules; |
53 | | - for ( var i = 0; i < rules.length; i++ ) { |
54 | | - var lookbackMatch = true; |
55 | | - if ( rules[i][1].length > 0 && rules[i][1].length <= lookback.length ) { |
56 | | - // Try to match rules[i][1] at the end of the lookback buffer |
57 | | - lookbackMatch = new RegExp( rules[i][1] + '$' ).test( lookback ); |
58 | | - } |
59 | | - var regex = new RegExp( rules[i][0] + '$' ); |
60 | | - if ( lookbackMatch && regex.test( str ) ) { |
61 | | - return str.replace( regex, rules[i][2] ); |
62 | | - } |
63 | | - } |
64 | | - // No matches, return the input |
65 | | - return str; |
66 | | - } |
67 | | - |
68 | | - /** |
69 | | - * Get the n characters in str that immediately precede pos |
70 | | - * Example: lastNChars( "foobarbaz", 5, 2 ) == "ba" |
71 | | - * @param str String to search in |
72 | | - * @param pos Position in str |
73 | | - * @param n Number of characters to go back from pos |
74 | | - * @return Substring of str, at most n characters long, immediately preceding pos |
75 | | - */ |
76 | | - function lastNChars( str, pos, n ) { |
77 | | - if ( n == 0 ) { |
78 | | - return ''; |
79 | | - } |
80 | | - if ( pos <= n ) { |
81 | | - return str.substr( 0, pos ); |
82 | | - } else { |
83 | | - return str.substr( pos - n, n); |
84 | | - } |
85 | | - } |
86 | | - |
87 | | - /** |
88 | | - * Find the point at which a and b diverge, i.e. the first position |
89 | | - * at which they don't have matching characters. |
90 | | - * @param a String |
91 | | - * @param b String |
92 | | - * @return Position at which a and b diverge, or -1 if a == b |
93 | | - */ |
94 | | - function firstDivergence( a, b ) { |
95 | | - var minLength = a.length < b.length ? a.length : b.length; |
96 | | - for ( var i = 0; i < minLength; i++ ) { |
97 | | - if ( a.charCodeAt( i ) !== b.charCodeAt( i ) ) { |
98 | | - return i; |
99 | | - } |
100 | | - } |
101 | | - return -1; |
102 | | - } |
103 | | - |
104 | | - function isShortcutKey( e ) { |
105 | | - return e.altKey == shortcutKey.altKey && |
106 | | - e.ctrlKey == shortcutKey.ctrlKey && |
107 | | - e.shiftKey == shortcutKey.shiftKey && |
108 | | - String.fromCharCode( e.which ).toLowerCase() == shortcutKey.key.toLowerCase() |
109 | | - } |
110 | | - |
111 | | - function shortcutText() { |
112 | | - var text = ''; |
113 | | - // TODO: Localize these things (in core, too) |
114 | | - if ( shortcutKey.ctrlKey ) { |
115 | | - text += 'Ctrl-'; |
116 | | - } |
117 | | - if ( shortcutKey.shiftKey ) { |
118 | | - text += 'Shift-'; |
119 | | - } |
120 | | - if ( shortcutKey.altKey ) { |
121 | | - text += 'Alt-'; |
122 | | - } |
123 | | - text += shortcutKey.key.toUpperCase(); |
124 | | - return text; |
125 | | - } |
126 | | - |
127 | | - function onkeydown( e ) { |
128 | | - // If the current scheme uses the alt key, ignore keydown for Alt+? combinations |
129 | | - if ( enabled && currentScheme.extended_keyboard && e.altKey && !e.ctrlKey ) { |
130 | | - e.stopPropagation(); |
131 | | - return false; // Not in original code -- does this belong here? |
132 | | - } else if ( isShortcutKey( e ) ) { |
133 | | - that.toggle(); |
134 | | - e.stopPropagation(); |
135 | | - return false; |
136 | | - } |
137 | | - return true; |
138 | | - } |
139 | | - |
140 | | - function onkeypress( e ) { |
141 | | - if ( !enabled ) { |
142 | | - return true; |
143 | | - } |
144 | | - |
145 | | - if ( e.which == 8 ) { // Backspace |
146 | | - // Blank the lookback buffer |
147 | | - $( this ).data( 'narayam-lookback', '' ); |
148 | | - return true; |
149 | | - } |
150 | | - |
151 | | - // Leave non-ASCII stuff alone, as well as anything involving |
152 | | - // Alt (except for extended keymaps), Ctrl and Meta |
153 | | - if ( e.which < 32 || ( e.altKey && !currentScheme.extended_keyboard ) || e.ctrlKey ) { |
154 | | - return true; |
155 | | - } |
156 | | - |
157 | | - var $this = $( this ); |
158 | | - var c = String.fromCharCode( e.which ); |
159 | | - var pos = $this.textSelection( 'getCaretPosition' ); |
160 | | - // Get the last few characters before the one the user just typed, |
161 | | - // to provide context for the transliteration regexes. |
162 | | - // We need to append c because it hasn't been added to $this.val() yet |
163 | | - var input = lastNChars( $this.val(), pos, currentScheme.lookbackLength ) + c; |
164 | | - var lookback = $this.data( 'narayam-lookback' ); |
165 | | - var replacement = transliterate( input, lookback, e.altKey ); |
166 | | - |
167 | | - // Update the lookback buffer |
168 | | - lookback += c; |
169 | | - if ( lookback.length > currentScheme.lookbackLength ) { |
170 | | - // The buffer is longer than needed, truncate it at the front |
171 | | - lookback = lookback.substring( lookback.length - currentScheme.lookbackLength ); |
172 | | - } |
173 | | - $this.data( 'narayam-lookback', lookback ); |
174 | | - |
175 | | - // textSelection() magic is expensive, so we avoid it as much as we can |
176 | | - if ( replacement == input ) { |
177 | | - return true; |
178 | | - } |
179 | | - // Drop a common prefix, if any |
180 | | - // TODO: Profile this, see if it's any faster |
181 | | - var divergingPos = firstDivergence( input, replacement ); |
182 | | - input = input.substring( divergingPos ); |
183 | | - replacement = replacement.substring( divergingPos ); |
184 | | - |
185 | | - // Select and replace the text |
186 | | - $this.textSelection( 'setSelection', { |
187 | | - 'start': pos - input.length + 1, |
188 | | - 'end': pos |
189 | | - } ); |
190 | | - $this.textSelection( 'encapsulateSelection', { |
191 | | - 'peri': replacement, |
192 | | - 'replace': true, |
193 | | - 'selectPeri': false |
194 | | - } ); |
195 | | - |
196 | | - e.stopPropagation(); |
197 | | - return false; |
198 | | - } |
199 | | - |
200 | | - function updateSchemeFromSelect() { |
201 | | - var scheme = $( this ).val(); |
202 | | - that.setScheme( scheme ); |
203 | | - $.cookie( 'narayam-scheme', scheme, { 'path': '/', 'expires': 30 } ); |
204 | | - } |
205 | | - |
206 | | - /* Public functions */ |
207 | | - |
208 | | - /** |
209 | | - * Add more inputs to apply Narayam to |
210 | | - * @param inputs A jQuery object holding one or more input or textarea elements, |
211 | | - * or an array of DOM elements, or a single DOM element, or a selector |
212 | | - */ |
213 | | - this.addInputs = function( inputs ) { |
214 | | - var $newInputs = $( inputs ); |
215 | | - $inputs = $inputs.add( $newInputs ); |
216 | | - $newInputs |
217 | | - .bind( 'keydown.narayam', onkeydown ) |
218 | | - .bind( 'keypress.narayam', onkeypress ) |
219 | | - .data( 'narayam-lookback', '' ); |
220 | | - if ( enabled ) { |
221 | | - $newInputs.addClass( 'narayam-input' ); |
222 | | - } |
223 | | - }; |
224 | | - |
225 | | - this.enable = function() { |
226 | | - if ( !enabled && currentScheme !== null ) { |
227 | | - $inputs.addClass( 'narayam-input' ); |
228 | | - $.cookie( 'narayam-enabled', '1', { 'path': '/', 'expires': 30 } ); |
229 | | - $( '#narayam-toggle' ).attr( 'checked', true ); |
230 | | - enabled = true; |
231 | | - } |
232 | | - }; |
233 | | - |
234 | | - this.disable = function() { |
235 | | - if ( enabled ) { |
236 | | - $inputs.removeClass( 'narayam-input' ); |
237 | | - $.cookie( 'narayam-enabled', '0', { 'path': '/', 'expires': 30 } ); |
238 | | - $( '#narayam-toggle' ).attr( 'checked', false ); |
239 | | - enabled = false; |
240 | | - } |
241 | | - }; |
242 | | - |
243 | | - this.toggle = function() { |
244 | | - if ( enabled ) { |
245 | | - that.disable(); |
246 | | - } else { |
247 | | - that.enable(); |
248 | | - } |
249 | | - }; |
250 | | - |
251 | | - /** |
252 | | - * Add a transliteration scheme. Schemes whose name is not in |
253 | | - * wgNarayamAvailableSchemes will be ignored. |
254 | | - * @param name Name of the scheme, must be unique |
255 | | - * @param data Object with scheme data |
256 | | - * @return True if added, false if not |
257 | | - */ |
258 | | - this.addScheme = function( name, data ) { |
259 | | - if ( name in availableSchemes ) { |
260 | | - schemes[name] = data; |
261 | | - return true; |
262 | | - } else { |
263 | | - return false; |
264 | | - } |
265 | | - }; |
266 | | - |
267 | | - this.setScheme = function( name ) { |
268 | | - if ( name in schemes ) { |
269 | | - currentScheme = schemes[name]; |
270 | | - $select.val( name ); |
271 | | - } |
272 | | - }; |
273 | | - |
274 | | - this.setup = function() { |
275 | | - // Build scheme dropdown |
276 | | - $select = $( '<select />' ); |
277 | | - var haveSchemes = false; |
278 | | - for ( var scheme in schemes ) { |
279 | | - $( '<option />' ) |
280 | | - .val( scheme ) |
281 | | - .text( mw.msg( schemes[scheme].namemsg ) ) |
282 | | - .appendTo( $select ); |
283 | | - haveSchemes = true; |
284 | | - } |
285 | | - $select.change( updateSchemeFromSelect ); |
286 | | - |
287 | | - if ( !haveSchemes ) { |
288 | | - // No schemes available, don't show the tool |
289 | | - return; |
290 | | - } |
291 | | - |
292 | | - // Build enable/disable checkbox and label |
293 | | - var $checkbox = $( '<input type="checkbox" id="narayam-toggle" />' ); |
294 | | - $checkbox |
295 | | - .attr( 'title', mw.msg( 'narayam-checkbox-tooltip' ) ) |
296 | | - .click( that.toggle ); |
297 | | - |
298 | | - var helppage = mw.msg( 'narayam-help-page' ); |
299 | | - var $label = $( '<label for="narayam-toggle" />' ); |
300 | | - $label |
301 | | - .text( mw.msg( 'narayam-toggle-ime', shortcutText() ) ) |
302 | | - .attr( 'title', mw.msg( 'narayam-checkbox-tooltip' ) ); |
303 | | - if ( helppage ) { |
304 | | - // Link to the help page |
305 | | - $label.wrapInner( $( '<a />' ).attr( 'href', mw.util.wikiGetlink( helppage ) ) ); |
306 | | - } |
307 | | - |
308 | | - var $checkboxAndLabel = $( '<span />' ) |
309 | | - .addClass( 'narayam-toggle-wrapper' ) |
310 | | - .append( $checkbox ) |
311 | | - .append( $label ); |
312 | | - var $spanWithEverything = $( '<span />' ) |
313 | | - .addClass( 'narayam-wrapper' ) |
314 | | - .append( $select ) |
315 | | - .append( $checkboxAndLabel ); |
316 | | - |
317 | | - // Put the dropdown and the checkbox at the beginning of the |
318 | | - // search form. This seems to be the most reliable way across skins. |
319 | | - $( '#searchform' ).prepend( $spanWithEverything ); |
320 | | - |
321 | | - // Restore state from cookies |
322 | | - var savedScheme = $.cookie( 'narayam-scheme' ); |
323 | | - if ( savedScheme && savedScheme in schemes ) { |
324 | | - that.setScheme( savedScheme ); |
325 | | - } else { |
326 | | - $select.change(); |
327 | | - } |
328 | | - var enabledCookie = $.cookie( 'narayam-enabled' ); |
329 | | - if ( enabledCookie == '1' || ( mw.config.get( 'wgNarayamEnableByDefault' ) && enabledCookie !== '0' ) ) { |
330 | | - that.enable(); |
331 | | - } |
332 | | - }; |
333 | | - |
334 | | -} )(); |
335 | | - |
336 | | -} )( jQuery ); |
Index: trunk/extensions/Narayam/ml_inscript_rules.js |
— | — | @@ -1,82 +0,0 @@ |
2 | | -/** |
3 | | - * Inscript regular expression rules table for Malayalam |
4 | | - * @author Junaid P V ([[user:Junaidpv]]) |
5 | | - * @date 2010-09-08 |
6 | | - * License: GPLv3 |
7 | | - */ |
8 | | -var rules = [ |
9 | | -['`', '','ൊ'], |
10 | | -['~', '','ഓ'], |
11 | | -['_', '','ഃ'], |
12 | | -['=', '','ൃ'], |
13 | | -['\\+', '','ഋ'], |
14 | | -['\\\\', '','\u200C'], |
15 | | -['q', '','ൗ'], |
16 | | -['Q', '','ഔ'], |
17 | | -['w', '','ൈ'], |
18 | | -['W', '','ഐ'], |
19 | | -['e', '','ാ'], |
20 | | -['E', '','ആ'], |
21 | | -['r', '','ീ'], |
22 | | -['R', '','ഈ'], |
23 | | -['t', '','ൂ'], |
24 | | -['T', '','ഊ'], |
25 | | -['y', '','ബ'], |
26 | | -['Y', '','ഭ'], |
27 | | -['u', '','ഹ'], |
28 | | -['U', '','ങ'], |
29 | | -['i', '','ഗ'], |
30 | | -['I', '','ഘ'], |
31 | | -['o', '','ദ'], |
32 | | -['O', '','ധ'], |
33 | | -['p', '','ജ'], |
34 | | -['P', '','ഝ'], |
35 | | -['\\[', '','ഡ'], |
36 | | -['\\{', '','ഢ'], |
37 | | -['\\]', '','\u200d'], |
38 | | -['\\}', '','ഞ'], |
39 | | -['a', '','ോ'], |
40 | | -['A', '','ഓ'], |
41 | | -['s', '','േ'], |
42 | | -['S', '','ഏ'], |
43 | | -['d', '','്'], |
44 | | -['D', '','അ'], |
45 | | -['f', '','ി'], |
46 | | -['F', '','ഇ'], |
47 | | -['g', '','ു'], |
48 | | -['G', '','ഉ'], |
49 | | -['h', '','പ'], |
50 | | -['H', '','ഫ'], |
51 | | -['j', '','ര'], |
52 | | -['J', '','റ'], |
53 | | -['k', '','ക'], |
54 | | -['K', '','ഖ'], |
55 | | -['l', '','ത'], |
56 | | -['L', '','ഥ'], |
57 | | -[';', '','ച'], |
58 | | -[':', '','ഛ'], |
59 | | -['\'', '','ട'], |
60 | | -['"', '','ഠ'], |
61 | | -['z', '','െ'], |
62 | | -['Z', '','എ'], |
63 | | -['x', '','ം'], |
64 | | -['c', '','മ'], |
65 | | -['C', '','ണ'], |
66 | | -['v', '','ന'], |
67 | | -['V', '', 'ഒ'], |
68 | | -['b', '','വ'], |
69 | | -['B', '','ഴ'], |
70 | | -['n', '','ല'], |
71 | | -['N', '','ള'], |
72 | | -['m', '','സ'], |
73 | | -['M', '','ശ'], |
74 | | -['<', '','ഷ'], |
75 | | -['/', '','യ'] |
76 | | -]; |
77 | | - |
78 | | -jQuery.narayam.addScheme( 'ml-inscript', { |
79 | | - 'namemsg': 'narayam-ml-inscript', |
80 | | - 'extended_keyboard': false, |
81 | | - 'lookbackLength': 0, |
82 | | - 'rules': rules |
83 | | -} ); |
Index: trunk/extensions/Narayam/bn_avro_rules.js |
— | — | @@ -1,196 +0,0 @@ |
2 | | -/** |
3 | | - * Avro layout regular expression rules table for Bengali script |
4 | | - * @author Junaid P V ([[user:Junaidpv]]) |
5 | | - * @date 2010-12-05 |
6 | | - * License: GPLv3, CC-BY-SA 3.0 |
7 | | - */ |
8 | | - |
9 | | -var rules = [ |
10 | | -['([ক-হড়ঢ়য়])্?ররi','[^o`]', '$1ৃ'], |
11 | | -['ররi','[^o`]', 'ঋ'], |
12 | | - |
13 | | -['ঙহo', '', 'ঙ্ঘ'], |
14 | | - |
15 | | -['([ক-হড়ঢ়য়])াZ', '[^o`]', '$1্যা'], |
16 | | - |
17 | | -['(([ক-হড়ঢ়য়])|য়)o','[^o`]', '$1'], // য় cannot be included in the range, why? everywhere else it is OK! |
18 | | -['([ক-হড়ঢ়য়])a','[^o`]', '$1া'], |
19 | | -['([ক-হড়ঢ়য়])i','[^o`]', '$1ি'], |
20 | | -['([ক-হড়ঢ়য়])(I|েe)','[^o`]', '$1ী'], |
21 | | -['([ক-হড়ঢ়য়])u','[^o`]', '$1ু'], |
22 | | -['([ক-হড়ঢ়য়])U','[^o`]', '$1ূ'], |
23 | | -['([ক-হড়ঢ়য়])o','[o`]', '$1ু'], |
24 | | -['([ক-হড়ঢ়য়])e','[^o`]', '$1ে'], |
25 | | -['([ক-হড়ঢ়য়])োI','[^o`]', '$1ৈ'], |
26 | | -['([ক-হড়ঢ়য়])O','[^o`]', '$1ো'], |
27 | | -['([ক-হড়ঢ়য়])োU','[^o`]', '$1ৌ'], |
28 | | - |
29 | | -['([ক-হড়ঢ়য়][িুেো]|[এইওউ])a','[^o`]', '$1য়া'], |
30 | | -['([ক-হড়ঢ়য়][াে]|[আএ])o', '[^o`]', '$1ও'], |
31 | | -//'চচh','[^o`]', 'চ্চ'], |
32 | | - |
33 | | -['([কঙলষস])(k|K)','[^o`]','$1্ক'], |
34 | | -['([ঙদল])(g|G)','[^o`]','$1্গ'], |
35 | | -['গg','[^o`]','জ্ঞ'], |
36 | | -['([চশ])c','[^o`]','$1্চ'], |
37 | | -['([জঞব])j','[^o`]','$1্জ'], |
38 | | -['নj','[^o`]','ঞ্জ'], |
39 | | -['([কটণনপলষস])T','[^o`]','$1্ট'], |
40 | | -['([ডণনল])D','[^o`]','$1্ড'], |
41 | | -['([গষহ])N','[^o`]','$1্ণ'], |
42 | | -['([কতনপশসহ])t','[^o`]','$1্ত'], |
43 | | -['([দনব])d','[^o`]','$1্দ'], |
44 | | -['([গঘণতধনপমশসহ])n','[^o`]','$1্ন'], |
45 | | -['([পমলষস])p','[^o`]','$1্প'], |
46 | | -['([স])f', '[^o`]', '$1্ফ'], |
47 | | -['([বমল])b','[^o`]','$1্ব'], |
48 | | -['([দম])(v|V)','[^o`]','$1্ভ'], |
49 | | -['([কগঙটণতদধনমলশষসহ])m','[^o`]','$1্ম'], |
50 | | -['([ক-ঘচ-ঝট-যলশ-হড়ঢ়য়])r','[^o`]','$1্র'], |
51 | | -['([কগপ-বমলশসহ])l','[^o`]','$1্ল'], |
52 | | -['([কনপ])s','[^o`]','$1্স'], |
53 | | -['([ক-হড়ঢ়য়])w','[^o`]','$1্ব'], |
54 | | -['([ক-হড়ঢ়য়])y','[^o`]','$1্য'], |
55 | | -['নc','[^o`]','ঞ্চ'], |
56 | | - |
57 | | -['ত`','`' ,'ৎ'], |
58 | | - |
59 | | -['ক্ক(h|H)','[^o`]','ক্ষ'], |
60 | | -['কশ(h|H)','[^o`]','ক্ষ'], |
61 | | -//'([অ-ঔা-ৌ])ররk','[^o]','$1র্ক'], |
62 | | - |
63 | | -['ররk','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ক'], |
64 | | -['ররg','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্গ'], |
65 | | -['ররc','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্চ'], |
66 | | -['ররj','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্জ'], |
67 | | -['ররT','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ট'], |
68 | | -['ররD','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ড'], |
69 | | -['ররN','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ণ'], |
70 | | -['ররt','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ত'], |
71 | | -['ররd','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্দ'], |
72 | | -['ররn','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ন'], |
73 | | -['ররp','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্প'], |
74 | | -['ররf','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ফ'], |
75 | | -['ররb','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ব'], |
76 | | -['ররv','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ভ'], |
77 | | -['ররm','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ম'], |
78 | | -['ররz','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্য'], |
79 | | -['ররl','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ল'], |
80 | | -['ররS','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্শ'], |
81 | | -['ররs','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্স'], |
82 | | -['ররh','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্হ'], |
83 | | -['ররR','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ড়'], |
84 | | -['রর(y|Y)','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্য়'], |
85 | | - |
86 | | -['ংo', '', 'ঙ্গ'], |
87 | | -['ংi', '', 'ঙ্গি'], |
88 | | -['ংI', '', 'ঙ্গী'], |
89 | | -['(ংu|ঙ্গo)', '', 'ঙ্গু'], |
90 | | -['ংU', '', 'ঙ্গূ'], |
91 | | -['ং', '', 'ঙ্গি'], |
92 | | -['ং', '', 'ঙ্গি'], |
93 | | - |
94 | | -['শ(h|H)','S', 'ষ'], |
95 | | - |
96 | | -['অo','[^`]', 'উ'], |
97 | | -['এe','[^o`]', 'ঈ'], |
98 | | - |
99 | | -['ক(h|H)','[^o`]', 'খ'], |
100 | | -['গ(h|H)','[^o`]', 'ঘ'], |
101 | | -['ণg','[^o`]', 'ঙ'], |
102 | | -['চ(h|H)','[^o`]', 'ছ'], |
103 | | -['জ(h|H)','[^o`]', 'ঝ'], |
104 | | -['ণG','[^o`]', 'ঞ'], |
105 | | -['ট(h|H)','[^o`]', 'ঠ'], |
106 | | -['ড(h|H)','[^o`]', 'ঢ'], |
107 | | -['ত(h|H)','[^o`]', 'থ'], |
108 | | -['দ(h|H)','[^o`]', 'ধ'], |
109 | | -['প(h|H)','[^o`]', 'ফ'], |
110 | | -['ব(h|H)','[^o`]', 'ভ'], |
111 | | -['(স(h|H))','[^o`]', 'শ'], |
112 | | -['ড়(h|H)','[^o`]', 'ঢ়'], |
113 | | -['ত্`','[^o`]', 'ৎ'], |
114 | | -['নg','[^o`]', 'ং'], |
115 | | -['ঃ`','[^o`]', ':'], |
116 | | -['ররi','[^o`]', 'ঋ'], |
117 | | -['ওI','[^o`]', 'ঐ'], |
118 | | -['ওU','[^o`]', 'ঔ'], |
119 | | - |
120 | | -['আ`', '', 'া'], |
121 | | -['ই`', '', 'ি'], |
122 | | -['ঈ`', '', 'ী'], |
123 | | -['উ`', '', 'ু'], |
124 | | -['ঊ`', '', 'ূ'], |
125 | | -['এ`', '', 'ে'], |
126 | | -['আ`', '', 'া'], |
127 | | -['আ`', '', 'া'], |
128 | | -['আ`', '', 'া'], |
129 | | -['আ`', '', 'া'], |
130 | | -['আ`', '', 'া'], |
131 | | -['আ`', '', 'া'], |
132 | | - |
133 | | -['([kKqQ])','' ,'ক'], |
134 | | -['(g|G)','' ,'গ'], |
135 | | -['(c|C)','' ,'চ'], |
136 | | -['(j|J)','' ,'জ'], |
137 | | -['T','' ,'ট'], |
138 | | -['D','' ,'ড'], |
139 | | -['N','' ,'ণ'], |
140 | | -['t','' ,'ত'], |
141 | | -['d','' ,'দ'], |
142 | | -['n','' ,'ন'], |
143 | | -['(p|P)','' ,'প'], |
144 | | -['f','' ,'ফ'], |
145 | | -['(b|B)','' ,'ব'], |
146 | | -['(v|V)','' ,'ভ'], |
147 | | -['(m|M)','' ,'ম'], |
148 | | -['z','' ,'য'], |
149 | | -['r','' ,'র'], |
150 | | -['(l|L)','' ,'ল'], |
151 | | -['S','' ,'শ'], |
152 | | -['s','' ,'স'], |
153 | | -['(h|H)','' ,'হ'], |
154 | | -['R','' ,'ড়'], |
155 | | -['w', '', 'ও'], |
156 | | -['x', '', 'ক্স'], |
157 | | -['(y|Y)','' ,'য়'], |
158 | | - |
159 | | -['Z','' ,'্য'], |
160 | | - |
161 | | -['o','' ,'অ'], |
162 | | -['(a|A)','' ,'আ'], |
163 | | -['i','' ,'ই'], |
164 | | -['I','' ,'ঈ'], |
165 | | -['u','' ,'উ'], |
166 | | -['U','' ,'ঊ'], |
167 | | -['(e|E)','' ,'এ'], |
168 | | -['O','' ,'ও'], |
169 | | - |
170 | | -['0','' ,'০'], |
171 | | -['1','' ,'১'], |
172 | | -['2','' ,'২'], |
173 | | -['3','' ,'৩'], |
174 | | -['4','' ,'৪'], |
175 | | -['5','' ,'৫'], |
176 | | -['6','' ,'৬'], |
177 | | -['7','' ,'৭'], |
178 | | -['8','' ,'৮'], |
179 | | -['9','' ,'৯'], |
180 | | - |
181 | | -['\\\\\\.','' ,'.'], |
182 | | - |
183 | | -[',,','' ,'্'], |
184 | | -['\\:','' ,'ঃ'], |
185 | | -['\\^','' ,'ঁ'], |
186 | | -['\\.','' ,'।'], |
187 | | -['\\$','' ,'৳'], |
188 | | -['ঃ`','' ,':'], |
189 | | -['`','' ,''] |
190 | | -]; |
191 | | - |
192 | | -jQuery.narayam.addScheme( 'bn-avro', { |
193 | | - 'namemsg': 'narayam-bn-avro', |
194 | | - 'extended_keyboard': false, |
195 | | - 'lookbackLength': 5, |
196 | | - 'rules': rules |
197 | | -} ); |
Index: trunk/extensions/Narayam/ta99_rules.js |
— | — | @@ -1,190 +0,0 @@ |
2 | | -/** |
3 | | - * Regular expression rules table for Tamil 99 input method |
4 | | - * @author Junaid P V ([[user:Junaidpv]]) |
5 | | - * @date 2010-11-20 |
6 | | - * License: GPLv3, CC-BY-SA 3.0 |
7 | | - */ |
8 | | - |
9 | | - // Normal rules |
10 | | -var rules = [ |
11 | | -['([க-ஹ])h','a', '$1க'], |
12 | | -['([க-ஹ])b','a', '$1ங'], |
13 | | -['([க-ஹ])\\[','a', '$1ச'], |
14 | | -['([க-ஹ])E','a', '$1ஜ'], |
15 | | -['([க-ஹ])\\]','a', '$1ஞ'], |
16 | | -['([க-ஹ])o','a', '$1ட'], |
17 | | -['([க-ஹ])p','a', '$1ண'], |
18 | | -['([க-ஹ])l','a', '$1த'], |
19 | | -['([க-ஹ]);','a', '$1ந'], |
20 | | -['([க-ஹ])i','a', '$1ன'], |
21 | | -['([க-ஹ])j','a', '$1ப'], |
22 | | -['([க-ஹ])k','a', '$1ம'], |
23 | | -["([க-ஹ])'",'a', '$1ய'], |
24 | | -['([க-ஹ])m','a', '$1ர'], |
25 | | -['([க-ஹ])u','a', '$1ற'], |
26 | | -['([க-ஹ])n','a', '$1ல'], |
27 | | -['([க-ஹ])y','a', '$1ள'], |
28 | | -['([க-ஹ])/','a', '$1ழ'], |
29 | | -['([க-ஹ])v','a', '$1வ'], |
30 | | -// void |
31 | | -['([க-ஹ])W','a', '$1ஷ'], |
32 | | -['([க-ஹ])Q','a', '$1ஸ'], |
33 | | -['([க-ஹ])R','a', '$1ஹ'], |
34 | | - |
35 | | - |
36 | | -['க்கh', '','க்கக்'], |
37 | | -['ங்ஙb', '','ங்ஙங்'], |
38 | | -['ச்ச\\[', '','ச்சச்'], |
39 | | -['ஜ்ஜE', '','ஜ்ஜஜ்'], |
40 | | -['ஞ்ஞ\\]', '','ஞ்ஞஞ்'], |
41 | | -['ட்டo', '','ட்டட்'], |
42 | | -['ண்ணp', '','ண்ணண்'], |
43 | | -['த்தl', '','த்தத்'], |
44 | | -['ந்ந;', '','ந்நந்'], |
45 | | -['ன்னi', '','ன்னன்'], |
46 | | -['ப்பj', '','ப்பப்'], |
47 | | -['ம்மk', '','ம்மம்'], |
48 | | -["ய்ய'", '','ய்யய்'], |
49 | | -['ர்ரm', '','ர்ரர்'], |
50 | | -['ற்றu', '','ற்றற்'], |
51 | | -['ல்லn', '','ல்லல்'], |
52 | | -['ள்ளy', '','ள்ளள்'], |
53 | | -['ழ்ழ/', '','ழ்ழழ்'], |
54 | | -['வ்வv', '','வ்வவ்'], |
55 | | -// void |
56 | | -['ஷ்ஷW', '','ஷ்ஷஷ்'], |
57 | | -['ஸ்ஸQ', '','ஸ்ஸஸ்'], |
58 | | -['ஹ்ஹR', '','ஹ்ஹஹ்'], |
59 | | - |
60 | | -['([க-ஹ])q', '','$1ா'], |
61 | | -['([க-ஹ])s', '','$1ி'], |
62 | | -['([க-ஹ])w', '','$1ீ'], |
63 | | -['([க-ஹ])d', '','$1ு'], |
64 | | -['([க-ஹ])e', '','$1ூ'], |
65 | | -['([க-ஹ])g', '','$1ெ'], |
66 | | -['([க-ஹ])t', '','$1ே'], |
67 | | -['([க-ஹ])r', '','$1ை'], |
68 | | -['([க-ஹ])c', '','$1ொ'], |
69 | | -['([க-ஹ])x', '','$1ோ'], |
70 | | -['([க-ஹ])z', '','$1ௌ'], |
71 | | - |
72 | | -['([க-ஹ])a', '','$1'], |
73 | | - |
74 | | -['கh', '','க்க'], |
75 | | -['ஙb', '','ங்ங'], |
76 | | -['ச\\[', '','ச்ச'], |
77 | | -['ஜE', '','ஜ்ஜ'], |
78 | | -['ஞ\\]', '','ஞ்ஞ'], |
79 | | -['டo', '','ட்ட'], |
80 | | -['ணp', '','ண்ண'], |
81 | | -['தl', '','த்த'], |
82 | | -['ந;', '','ந்ந'], |
83 | | -['னi', '','ன்ன'], |
84 | | -['பj', '','ப்ப'], |
85 | | -['மk', '','ம்ம'], |
86 | | -["ய'", '','ய்ய'], |
87 | | -['ரm', '','ர்ர'], |
88 | | -['றu', '','ற்ற'], |
89 | | -['லn', '','ல்ல'], |
90 | | -['ளy', '','ள்ள'], |
91 | | -['ழ/', '','ழ்ழ'], |
92 | | -['வv', '','வ்வ'], |
93 | | -// void |
94 | | -['ஷW', '','ஷ்ஷ'], |
95 | | -['ஸQ', '','ஸ்ஸ'], |
96 | | -['ஹR', '','ஹ்ஹ'], |
97 | | - |
98 | | -['நl', '','ந்த'], |
99 | | -['ஙh', '','ங்க'], |
100 | | -['னu', '','ன்ற'], |
101 | | -['ணo', '','ண்ட'], |
102 | | -['ஞ\\[', '','ஞ்ச'], |
103 | | -['மj', '','ம்ப'], |
104 | | - |
105 | | -['q', '','ஆ'], |
106 | | -['w', '','ஈ'], |
107 | | -['e', '','ஊ'], |
108 | | -['r', '','ஐ'], |
109 | | -['t', '','ஏ'], |
110 | | -['y', '','ள'], |
111 | | -['u', '','ற'], |
112 | | -['i', '','ன'], |
113 | | -['o', '','ட'], |
114 | | -['p', '','ண'], |
115 | | -['\\[', '','ச'], |
116 | | -['\\]', '','ஞ'], |
117 | | - |
118 | | -['a', '','அ'], |
119 | | -['s', '','இ'], |
120 | | -['d', '','உ'], |
121 | | -['f', '','்'], |
122 | | -['g', '','எ'], |
123 | | -['h', '','க'], |
124 | | -['j', '','ப'], |
125 | | -['k', '','ம'], |
126 | | -['l', '','த'], |
127 | | -[';', '','ந'], |
128 | | -["'", '','ய'], |
129 | | - |
130 | | -['z', '','ஔ'], |
131 | | -['x', '','ஓ'], |
132 | | -['c', '','ஒ'], |
133 | | -['v', '','வ'], |
134 | | -['b', '','ங'], |
135 | | -['n', '','ல'], |
136 | | -['m', '','ர'], |
137 | | -//',', '','ஆ'], |
138 | | -//'\\.', '','ஆ'], |
139 | | -['/', '','ழ'], |
140 | | - |
141 | | -['Q', '','ஸ'], |
142 | | -['W', '','ஷ'], |
143 | | -['E', '','ஜ'], |
144 | | -['R', '','ஹ'], |
145 | | -['T', '','க்ஷ'], |
146 | | -['Y', '','ஸ்ரீ'], |
147 | | -['U', '','ற'], |
148 | | -['I', '','ன'], |
149 | | -['O', '','['], |
150 | | -['P', '',']'], |
151 | | -//'\\{', '','ஆ'], |
152 | | -//'\\}', '','ஆ'], |
153 | | - |
154 | | -['A', '','௹'], |
155 | | -['S', '','௺'], |
156 | | -['D', '','௸'], |
157 | | -['F', '','ஃ'], |
158 | | -['G', '','எ'], |
159 | | -['H', '','க'], |
160 | | -['J', '','ப'], |
161 | | -['K', '','"'], |
162 | | -['L', '',','], |
163 | | -['\\:', '',';'], |
164 | | -['"', '',"'"], |
165 | | - |
166 | | -['Z', '','௳'], |
167 | | -['X', '','௴'], |
168 | | -['C', '','௵'], |
169 | | -['V', '','௶'], |
170 | | -['B', '','௷'], |
171 | | -['N', '','ல'], |
172 | | -['M', '','ர'], |
173 | | - |
174 | | -['\\\\0', '','\u0be6'], |
175 | | -['\\\\1', '','௧'], |
176 | | -['\\\\2', '','௨'], |
177 | | -['\\\\3', '','௩'], |
178 | | -['\\\\4', '','௪'], |
179 | | -['\\\\5', '','௫'], |
180 | | -['\\\\6', '','௬'], |
181 | | -['\\\\7', '','௭'], |
182 | | -['\\\\8', '','௮'], |
183 | | -['\\\\9', '','௯'] |
184 | | -]; |
185 | | - |
186 | | -jQuery.narayam.addScheme( 'ta99', { |
187 | | - 'namemsg': 'narayam-ta99', |
188 | | - 'extended_keyboard': false, |
189 | | - 'lookbackLength': 1, |
190 | | - 'rules': rules |
191 | | -} ); |
Index: trunk/extensions/Narayam/bn_nkb_rules.js |
— | — | @@ -1,137 +0,0 @@ |
2 | | -/** |
3 | | - * Regular expression rules table for Bengali National Keyboard |
4 | | - * @author Junaid P V ([[user:Junaidpv]]) |
5 | | - * @date 2010-12-13 |
6 | | - * @credits From the standard developed by Bangladesh Computer Council, |
7 | | - * Ministry of Science and Information & Communication Technology, Govt. of Bangladesh |
8 | | - * License: GPLv3, CC-BY-SA 3.0 |
9 | | - */ |
10 | | - |
11 | | -// Normal rules |
12 | | -var rules = [ |
13 | | -['1', '', '১'], |
14 | | -['2', '', '২'], |
15 | | -['3', '', '৩'], |
16 | | -['4', '', '৪'], |
17 | | -['5', '', '৫'], |
18 | | -['6', '', '৬'], |
19 | | -['7', '', '৭'], |
20 | | -['8', '', '৮'], |
21 | | -['9', '', '৯'], |
22 | | -['0', '', '০'], |
23 | | - |
24 | | -['q', '', 'ঙ'], |
25 | | -['w', '', 'য'], |
26 | | -['e', '', 'ড'], |
27 | | -['r', '', 'প'], |
28 | | -['t', '', 'ট'], |
29 | | -['y', '', 'চ'], |
30 | | -['u', '', 'জ'], |
31 | | -['i', '', 'হ'], |
32 | | -['o', '', 'গ'], |
33 | | -['p', '', 'ড়'], |
34 | | - |
35 | | -['a', '', 'ৃ'], |
36 | | -['s', '', 'ু'], |
37 | | -['d', '', 'ি'], |
38 | | -['f', '', 'ব'], |
39 | | -['g', '', '্'], |
40 | | -['h', '', 'া'], |
41 | | -['j', '', 'ক'], |
42 | | -['k', '', 'ত'], |
43 | | -['l', '', 'দ'], |
44 | | - |
45 | | -['z', '', 'ঁ'], |
46 | | -['x', '', 'ো'], |
47 | | -['c', '', 'ে'], |
48 | | -['v', '', 'র'], |
49 | | -['b', '', 'ন'], |
50 | | -['n', '', 'স'], |
51 | | -['m', '', 'ম'], |
52 | | - |
53 | | -['Q', '', 'ং'], |
54 | | -['W', '', 'য়'], |
55 | | -['E', '', 'ঢ'], |
56 | | -['R', '', 'ফ'], |
57 | | -['T', '', 'ঠ'], |
58 | | -['Y', '', 'ছ'], |
59 | | -['U', '', 'ঝ'], |
60 | | -['I', '', 'ঞ'], |
61 | | -['O', '', 'ঘ'], |
62 | | -['P', '', 'ঢ়'], |
63 | | - |
64 | | -['A', '', 'ৗ'], |
65 | | -['S', '', 'ূ'], |
66 | | -['D', '', 'ী'], |
67 | | -['F', '', 'ভ'], |
68 | | -['G', '', '।'], |
69 | | -['H', '', 'অ'], |
70 | | -['J', '', 'খ'], |
71 | | -['K', '', 'থ'], |
72 | | -['L', '', 'ধ'], |
73 | | - |
74 | | -['Z', '', 'ঃ'], |
75 | | -['X', '', 'ৌ'], |
76 | | -['C', '', 'ৈ'], |
77 | | -['V', '', 'ল'], |
78 | | -['B', '', 'ণ'], |
79 | | -['N', '', 'ষ'], |
80 | | -['M', '', 'শ'] |
81 | | -]; |
82 | | - |
83 | | -// Extended layout for National Keyboard. Works in Firefox only |
84 | | -var rules_x = [ |
85 | | -['1', '', '৴'], |
86 | | -['2', '', '৵'], |
87 | | -['3', '', '৶'], |
88 | | -['4', '', '৳'], |
89 | | -['5', '', '৷'], |
90 | | -['6', '', '৸'], |
91 | | -['7', '', 'ं'], |
92 | | -['0', '', '৹'], |
93 | | -['\\-', '', '\u200C'], |
94 | | -['\\=', '', '\u200D'], |
95 | | - |
96 | | -['q', '', 'ৢ'], |
97 | | -['w', '', '্য'], |
98 | | -['e', '', 'ৄ'], |
99 | | -['i', '', 'ঽ'], |
100 | | - |
101 | | -['a', '', 'ঋ'], |
102 | | -['s', '', 'উ'], |
103 | | -['d', '', 'ই'], |
104 | | -['f', '', 'ৰ'], |
105 | | -['g', '', '॥'], |
106 | | -['h', '', 'আ'], |
107 | | -['j', '', ''], |
108 | | -['k', '', 'ঢ'], |
109 | | -['l', '', 'ঌ'], |
110 | | - |
111 | | -['z', '', '৺'], |
112 | | -['x', '', 'ও'], |
113 | | -['c', '', 'এ'], |
114 | | -['v', '', '্র'], |
115 | | -['\\.', '', '়'], |
116 | | - |
117 | | -['\\$', '', '৲'], |
118 | | -['\\^', '', ''], |
119 | | - |
120 | | -['Q', '', 'ৣ'], |
121 | | - |
122 | | -['A', '', 'ৠ'], |
123 | | -['S', '', 'ঊ'], |
124 | | -['D', '', 'ঈ'], |
125 | | -['F', '', 'ৱ'], |
126 | | -['L', '', 'ৡ'], |
127 | | - |
128 | | -['X', '', 'ঔ'], |
129 | | -['C', '', 'ঐ'] |
130 | | -]; |
131 | | - |
132 | | -jQuery.narayam.addScheme( 'bn-nkb', { |
133 | | - 'namemsg': 'narayam-bn-nkb', |
134 | | - 'extended_keyboard': true, |
135 | | - 'lookbackLength': 0, |
136 | | - 'rules': rules, |
137 | | - 'rules_x': rules_x |
138 | | -} ); |
Index: trunk/extensions/Narayam/ext.narayam.rules.ta99.js |
— | — | @@ -0,0 +1,190 @@ |
| 2 | +/** |
| 3 | + * Regular expression rules table for Tamil 99 input method |
| 4 | + * @author Junaid P V ([[user:Junaidpv]]) |
| 5 | + * @date 2010-11-20 |
| 6 | + * License: GPLv3, CC-BY-SA 3.0 |
| 7 | + */ |
| 8 | + |
| 9 | + // Normal rules |
| 10 | +var rules = [ |
| 11 | +['([க-ஹ])h','a', '$1க'], |
| 12 | +['([க-ஹ])b','a', '$1ங'], |
| 13 | +['([க-ஹ])\\[','a', '$1ச'], |
| 14 | +['([க-ஹ])E','a', '$1ஜ'], |
| 15 | +['([க-ஹ])\\]','a', '$1ஞ'], |
| 16 | +['([க-ஹ])o','a', '$1ட'], |
| 17 | +['([க-ஹ])p','a', '$1ண'], |
| 18 | +['([க-ஹ])l','a', '$1த'], |
| 19 | +['([க-ஹ]);','a', '$1ந'], |
| 20 | +['([க-ஹ])i','a', '$1ன'], |
| 21 | +['([க-ஹ])j','a', '$1ப'], |
| 22 | +['([க-ஹ])k','a', '$1ம'], |
| 23 | +["([க-ஹ])'",'a', '$1ய'], |
| 24 | +['([க-ஹ])m','a', '$1ர'], |
| 25 | +['([க-ஹ])u','a', '$1ற'], |
| 26 | +['([க-ஹ])n','a', '$1ல'], |
| 27 | +['([க-ஹ])y','a', '$1ள'], |
| 28 | +['([க-ஹ])/','a', '$1ழ'], |
| 29 | +['([க-ஹ])v','a', '$1வ'], |
| 30 | +// void |
| 31 | +['([க-ஹ])W','a', '$1ஷ'], |
| 32 | +['([க-ஹ])Q','a', '$1ஸ'], |
| 33 | +['([க-ஹ])R','a', '$1ஹ'], |
| 34 | + |
| 35 | + |
| 36 | +['க்கh', '','க்கக்'], |
| 37 | +['ங்ஙb', '','ங்ஙங்'], |
| 38 | +['ச்ச\\[', '','ச்சச்'], |
| 39 | +['ஜ்ஜE', '','ஜ்ஜஜ்'], |
| 40 | +['ஞ்ஞ\\]', '','ஞ்ஞஞ்'], |
| 41 | +['ட்டo', '','ட்டட்'], |
| 42 | +['ண்ணp', '','ண்ணண்'], |
| 43 | +['த்தl', '','த்தத்'], |
| 44 | +['ந்ந;', '','ந்நந்'], |
| 45 | +['ன்னi', '','ன்னன்'], |
| 46 | +['ப்பj', '','ப்பப்'], |
| 47 | +['ம்மk', '','ம்மம்'], |
| 48 | +["ய்ய'", '','ய்யய்'], |
| 49 | +['ர்ரm', '','ர்ரர்'], |
| 50 | +['ற்றu', '','ற்றற்'], |
| 51 | +['ல்லn', '','ல்லல்'], |
| 52 | +['ள்ளy', '','ள்ளள்'], |
| 53 | +['ழ்ழ/', '','ழ்ழழ்'], |
| 54 | +['வ்வv', '','வ்வவ்'], |
| 55 | +// void |
| 56 | +['ஷ்ஷW', '','ஷ்ஷஷ்'], |
| 57 | +['ஸ்ஸQ', '','ஸ்ஸஸ்'], |
| 58 | +['ஹ்ஹR', '','ஹ்ஹஹ்'], |
| 59 | + |
| 60 | +['([க-ஹ])q', '','$1ா'], |
| 61 | +['([க-ஹ])s', '','$1ி'], |
| 62 | +['([க-ஹ])w', '','$1ீ'], |
| 63 | +['([க-ஹ])d', '','$1ு'], |
| 64 | +['([க-ஹ])e', '','$1ூ'], |
| 65 | +['([க-ஹ])g', '','$1ெ'], |
| 66 | +['([க-ஹ])t', '','$1ே'], |
| 67 | +['([க-ஹ])r', '','$1ை'], |
| 68 | +['([க-ஹ])c', '','$1ொ'], |
| 69 | +['([க-ஹ])x', '','$1ோ'], |
| 70 | +['([க-ஹ])z', '','$1ௌ'], |
| 71 | + |
| 72 | +['([க-ஹ])a', '','$1'], |
| 73 | + |
| 74 | +['கh', '','க்க'], |
| 75 | +['ஙb', '','ங்ங'], |
| 76 | +['ச\\[', '','ச்ச'], |
| 77 | +['ஜE', '','ஜ்ஜ'], |
| 78 | +['ஞ\\]', '','ஞ்ஞ'], |
| 79 | +['டo', '','ட்ட'], |
| 80 | +['ணp', '','ண்ண'], |
| 81 | +['தl', '','த்த'], |
| 82 | +['ந;', '','ந்ந'], |
| 83 | +['னi', '','ன்ன'], |
| 84 | +['பj', '','ப்ப'], |
| 85 | +['மk', '','ம்ம'], |
| 86 | +["ய'", '','ய்ய'], |
| 87 | +['ரm', '','ர்ர'], |
| 88 | +['றu', '','ற்ற'], |
| 89 | +['லn', '','ல்ல'], |
| 90 | +['ளy', '','ள்ள'], |
| 91 | +['ழ/', '','ழ்ழ'], |
| 92 | +['வv', '','வ்வ'], |
| 93 | +// void |
| 94 | +['ஷW', '','ஷ்ஷ'], |
| 95 | +['ஸQ', '','ஸ்ஸ'], |
| 96 | +['ஹR', '','ஹ்ஹ'], |
| 97 | + |
| 98 | +['நl', '','ந்த'], |
| 99 | +['ஙh', '','ங்க'], |
| 100 | +['னu', '','ன்ற'], |
| 101 | +['ணo', '','ண்ட'], |
| 102 | +['ஞ\\[', '','ஞ்ச'], |
| 103 | +['மj', '','ம்ப'], |
| 104 | + |
| 105 | +['q', '','ஆ'], |
| 106 | +['w', '','ஈ'], |
| 107 | +['e', '','ஊ'], |
| 108 | +['r', '','ஐ'], |
| 109 | +['t', '','ஏ'], |
| 110 | +['y', '','ள'], |
| 111 | +['u', '','ற'], |
| 112 | +['i', '','ன'], |
| 113 | +['o', '','ட'], |
| 114 | +['p', '','ண'], |
| 115 | +['\\[', '','ச'], |
| 116 | +['\\]', '','ஞ'], |
| 117 | + |
| 118 | +['a', '','அ'], |
| 119 | +['s', '','இ'], |
| 120 | +['d', '','உ'], |
| 121 | +['f', '','்'], |
| 122 | +['g', '','எ'], |
| 123 | +['h', '','க'], |
| 124 | +['j', '','ப'], |
| 125 | +['k', '','ம'], |
| 126 | +['l', '','த'], |
| 127 | +[';', '','ந'], |
| 128 | +["'", '','ய'], |
| 129 | + |
| 130 | +['z', '','ஔ'], |
| 131 | +['x', '','ஓ'], |
| 132 | +['c', '','ஒ'], |
| 133 | +['v', '','வ'], |
| 134 | +['b', '','ங'], |
| 135 | +['n', '','ல'], |
| 136 | +['m', '','ர'], |
| 137 | +//',', '','ஆ'], |
| 138 | +//'\\.', '','ஆ'], |
| 139 | +['/', '','ழ'], |
| 140 | + |
| 141 | +['Q', '','ஸ'], |
| 142 | +['W', '','ஷ'], |
| 143 | +['E', '','ஜ'], |
| 144 | +['R', '','ஹ'], |
| 145 | +['T', '','க்ஷ'], |
| 146 | +['Y', '','ஸ்ரீ'], |
| 147 | +['U', '','ற'], |
| 148 | +['I', '','ன'], |
| 149 | +['O', '','['], |
| 150 | +['P', '',']'], |
| 151 | +//'\\{', '','ஆ'], |
| 152 | +//'\\}', '','ஆ'], |
| 153 | + |
| 154 | +['A', '','௹'], |
| 155 | +['S', '','௺'], |
| 156 | +['D', '','௸'], |
| 157 | +['F', '','ஃ'], |
| 158 | +['G', '','எ'], |
| 159 | +['H', '','க'], |
| 160 | +['J', '','ப'], |
| 161 | +['K', '','"'], |
| 162 | +['L', '',','], |
| 163 | +['\\:', '',';'], |
| 164 | +['"', '',"'"], |
| 165 | + |
| 166 | +['Z', '','௳'], |
| 167 | +['X', '','௴'], |
| 168 | +['C', '','௵'], |
| 169 | +['V', '','௶'], |
| 170 | +['B', '','௷'], |
| 171 | +['N', '','ல'], |
| 172 | +['M', '','ர'], |
| 173 | + |
| 174 | +['\\\\0', '','\u0be6'], |
| 175 | +['\\\\1', '','௧'], |
| 176 | +['\\\\2', '','௨'], |
| 177 | +['\\\\3', '','௩'], |
| 178 | +['\\\\4', '','௪'], |
| 179 | +['\\\\5', '','௫'], |
| 180 | +['\\\\6', '','௬'], |
| 181 | +['\\\\7', '','௭'], |
| 182 | +['\\\\8', '','௮'], |
| 183 | +['\\\\9', '','௯'] |
| 184 | +]; |
| 185 | + |
| 186 | +jQuery.narayam.addScheme( 'ta99', { |
| 187 | + 'namemsg': 'narayam-ta99', |
| 188 | + 'extended_keyboard': false, |
| 189 | + 'lookbackLength': 1, |
| 190 | + 'rules': rules |
| 191 | +} ); |
Property changes on: trunk/extensions/Narayam/ext.narayam.rules.ta99.js |
___________________________________________________________________ |
Added: svn:eol-style |
1 | 192 | + native |
Index: trunk/extensions/Narayam/ext.narayam.rules.bn-inscript.js |
— | — | @@ -0,0 +1,126 @@ |
| 2 | +/** |
| 3 | + * InScript regular expression rules table for Bengali script |
| 4 | + * According to CDAC's "Enhanced InScript Keyboard Layout 5.2" |
| 5 | + * @author Junaid P V ([[user:Junaidpv]]) |
| 6 | + * @date 2010-12-12 |
| 7 | + * License: GPLv3, CC-BY-SA 3.0 |
| 8 | + */ |
| 9 | + |
| 10 | +// Normal rules |
| 11 | +var rules = [ |
| 12 | +['X', '', 'ঁ'], |
| 13 | +['x', '', 'ং'], |
| 14 | +['_', '', 'ঃ'], |
| 15 | +['D', '', 'অ'], |
| 16 | +['E', '', 'আ'], |
| 17 | +['F', '', 'ই'], |
| 18 | +['R', '', 'ঈ'], |
| 19 | +['G', '', 'উ'], |
| 20 | +['T', '', 'ঊ'], |
| 21 | +['\\+', '', 'ঋ'], |
| 22 | +['S', '', 'এ'], |
| 23 | +['W', '', 'ঐ'], |
| 24 | +['A', '', 'ও'], |
| 25 | +['Q', '', 'ঔ'], |
| 26 | +['k', '', 'ক'], |
| 27 | +['K', '', 'খ'], |
| 28 | +['i', '', 'গ'], |
| 29 | +['I', '', 'ঘ'], |
| 30 | +['U', '', 'ঙ'], |
| 31 | +[';', '', 'চ'], |
| 32 | +['\\:', '', 'ছ'], |
| 33 | +['p', '', 'জ'], |
| 34 | +['P', '', 'ঝ'], |
| 35 | +['\\}', '', 'ঞ'], |
| 36 | +["'", '', 'ট'], |
| 37 | +['"', '', 'ঠ'], |
| 38 | +['\\[', '', 'ড'], |
| 39 | +['\\{', '', 'ঢ'], |
| 40 | +['C', '', 'ণ'], |
| 41 | +['l', '', 'ত'], |
| 42 | +['L', '', 'থ'], |
| 43 | +['o', '', 'দ'], |
| 44 | +['O', '', 'ধ'], |
| 45 | +['v', '', 'ন'], |
| 46 | +['h', '', 'প'], |
| 47 | +['H', '', 'ফ'], |
| 48 | +['y', '', 'ব'], |
| 49 | +['Y', '', 'ভ'], |
| 50 | +['c', '', 'ম'], |
| 51 | +['\\?', '', 'য'], |
| 52 | +['j', '', 'র'], |
| 53 | +['J', '', 'ৎ'], |
| 54 | +['n', '', 'ল'], |
| 55 | +['M', '', 'শ'], |
| 56 | +['\\<', '', 'ষ'], |
| 57 | +['m', '', 'স'], |
| 58 | +['u', '', 'হ'], |
| 59 | +['\\]', '', '়'], |
| 60 | +['e', '', 'া'], |
| 61 | +['f', '', 'ি'], |
| 62 | +['r', '', 'ী'], |
| 63 | +['g', '', 'ু'], |
| 64 | +['t', '', 'ূ'], |
| 65 | +['\\=', '', 'ৃ'], |
| 66 | +['s', '', 'ে'], |
| 67 | +['w', '', 'ৈ'], |
| 68 | +['a', '', 'ো'], |
| 69 | +['q', '', 'ৌ'], |
| 70 | +['d', '', '্'], |
| 71 | +['/', '', 'য়'], |
| 72 | +['\\>', '', ''], |
| 73 | +['0', '', '০'], |
| 74 | +['1', '', '১'], |
| 75 | +['2', '', '২'], |
| 76 | +['3', '', '৩'], |
| 77 | +['4', '', '৪'], |
| 78 | +['5', '', '৫'], |
| 79 | +['6', '', '৬'], |
| 80 | +['7', '', '৭'], |
| 81 | +['8', '', '৮'], |
| 82 | +['9', '', '৯'], |
| 83 | +['z', '', 'ʼ'], |
| 84 | +['\\!', '', 'অ্যা'], |
| 85 | +['\\#', '', '্র'], |
| 86 | +['\\$', '', 'র্'], |
| 87 | +['\\%', '', 'জ্ঞ'], |
| 88 | +['\\^', '', 'ত্র'], |
| 89 | +['\\&', '', 'ক্ষ'], |
| 90 | +['\\*', '', 'শ্র'], |
| 91 | +['\\(', '', '\u200D'], |
| 92 | +['\\)', '', '\u200C'] |
| 93 | +]; |
| 94 | + |
| 95 | +// Extended layout for InScript. Works in Firefox only |
| 96 | +var rules_x = [ |
| 97 | +['F', '', 'ঌ'], |
| 98 | +['\\>', '', 'ঽ'], |
| 99 | +['\\=', '', 'ৠ'], |
| 100 | +['l', '', 'ৎ'], |
| 101 | +['\\[', '', 'ড়'], |
| 102 | +['\\{', '', 'ঢ়'], |
| 103 | +['\\+', '', 'ৠ'], |
| 104 | +['R', '', 'ৡ'], |
| 105 | +['f', '', 'ৢ'], |
| 106 | +['r', '', 'ৣ'], |
| 107 | +['\\.', '', ''], |
| 108 | +['x', '', '৺'], |
| 109 | +['\\<', '', '৲'], |
| 110 | +[',', '', '৳'], |
| 111 | +['\\!', '', '৴'], |
| 112 | +['\\@', '', '৵'], |
| 113 | +['\\#', '', '৶'], |
| 114 | +['\\$', '', '৷'], |
| 115 | +['\\%', '', '৸'], |
| 116 | +['\\^', '', '৹'], |
| 117 | +['\\?', '', '৻'], |
| 118 | +['4', '', '₹'] |
| 119 | +]; |
| 120 | + |
| 121 | +jQuery.narayam.addScheme( 'bn-inscript', { |
| 122 | + 'namemsg': 'narayam-bn-inscript', |
| 123 | + 'extended_keyboard': true, |
| 124 | + 'lookbackLength': 0, |
| 125 | + 'rules': rules, |
| 126 | + 'rules_x': rules_x |
| 127 | +} ); |
Property changes on: trunk/extensions/Narayam/ext.narayam.rules.bn-inscript.js |
___________________________________________________________________ |
Added: svn:eol-style |
1 | 128 | + native |
Index: trunk/extensions/Narayam/ext.narayam.core.js |
— | — | @@ -0,0 +1,335 @@ |
| 2 | +/** |
| 3 | + * Narayam |
| 4 | + * Input field rewriter tool for web pages |
| 5 | + * @author Junaid P V ([[user:Junaidpv]])(http://junaidpv.in) |
| 6 | + * @date 2010-12-18 (Based on naaraayam transliteration tool I first wrote on 2010-05-19) |
| 7 | + * @version 3.0 |
| 8 | + * Last update: 2010-11-28 |
| 9 | + * License: GPLv3, CC-BY-SA 3.0 |
| 10 | + */ |
| 11 | + |
| 12 | +( function( $ ) { |
| 13 | +$.narayam = new ( function() { |
| 14 | + /* Private members */ |
| 15 | + |
| 16 | + // Reference to this object |
| 17 | + var that = this; |
| 18 | + // jQuery array holding all text inputs Narayam applies to |
| 19 | + var $inputs = $( [] ); |
| 20 | + // Input method dropdown |
| 21 | + var $select = $( [] ); |
| 22 | + // Whether Narayam is enabled |
| 23 | + var enabled = false; |
| 24 | + // Registered schemes |
| 25 | + var schemes = {}; |
| 26 | + // List of scheme names, ordered for presentation purposes |
| 27 | + // Schemes not in this list won't be allowed to register |
| 28 | + // This object is formatted as { 'schemename': '', 'schemename2': '', ... } |
| 29 | + // for easy searching |
| 30 | + var availableSchemes = mw.config.get( 'wgNarayamAvailableSchemes' ) || {}; |
| 31 | + // Currently selected scheme |
| 32 | + var currentScheme = null; |
| 33 | + // Shortcut key |
| 34 | + var shortcutKey = mw.config.get( 'wgNarayamShortcutKey' ) || { |
| 35 | + altKey: false, |
| 36 | + ctrlKey: false, |
| 37 | + shiftKey: false, |
| 38 | + key: null |
| 39 | + }; |
| 40 | + |
| 41 | + /* Private functions */ |
| 42 | + |
| 43 | + /** |
| 44 | + * Transliterate a string using the current scheme |
| 45 | + * @param str String to transliterate |
| 46 | + * @param lookback The lookback buffer |
| 47 | + * @param useExtended Whether to use the extended part of the scheme |
| 48 | + * @return Transliterated string, or str if no applicable transliteration found. |
| 49 | + */ |
| 50 | + function transliterate( str, lookback, useExtended ) { |
| 51 | + var rules = currentScheme.extended_keyboard && useExtended ? |
| 52 | + currentScheme.rules_x : currentScheme.rules; |
| 53 | + for ( var i = 0; i < rules.length; i++ ) { |
| 54 | + var lookbackMatch = true; |
| 55 | + if ( rules[i][1].length > 0 && rules[i][1].length <= lookback.length ) { |
| 56 | + // Try to match rules[i][1] at the end of the lookback buffer |
| 57 | + lookbackMatch = new RegExp( rules[i][1] + '$' ).test( lookback ); |
| 58 | + } |
| 59 | + var regex = new RegExp( rules[i][0] + '$' ); |
| 60 | + if ( lookbackMatch && regex.test( str ) ) { |
| 61 | + return str.replace( regex, rules[i][2] ); |
| 62 | + } |
| 63 | + } |
| 64 | + // No matches, return the input |
| 65 | + return str; |
| 66 | + } |
| 67 | + |
| 68 | + /** |
| 69 | + * Get the n characters in str that immediately precede pos |
| 70 | + * Example: lastNChars( "foobarbaz", 5, 2 ) == "ba" |
| 71 | + * @param str String to search in |
| 72 | + * @param pos Position in str |
| 73 | + * @param n Number of characters to go back from pos |
| 74 | + * @return Substring of str, at most n characters long, immediately preceding pos |
| 75 | + */ |
| 76 | + function lastNChars( str, pos, n ) { |
| 77 | + if ( n == 0 ) { |
| 78 | + return ''; |
| 79 | + } |
| 80 | + if ( pos <= n ) { |
| 81 | + return str.substr( 0, pos ); |
| 82 | + } else { |
| 83 | + return str.substr( pos - n, n); |
| 84 | + } |
| 85 | + } |
| 86 | + |
| 87 | + /** |
| 88 | + * Find the point at which a and b diverge, i.e. the first position |
| 89 | + * at which they don't have matching characters. |
| 90 | + * @param a String |
| 91 | + * @param b String |
| 92 | + * @return Position at which a and b diverge, or -1 if a == b |
| 93 | + */ |
| 94 | + function firstDivergence( a, b ) { |
| 95 | + var minLength = a.length < b.length ? a.length : b.length; |
| 96 | + for ( var i = 0; i < minLength; i++ ) { |
| 97 | + if ( a.charCodeAt( i ) !== b.charCodeAt( i ) ) { |
| 98 | + return i; |
| 99 | + } |
| 100 | + } |
| 101 | + return -1; |
| 102 | + } |
| 103 | + |
| 104 | + function isShortcutKey( e ) { |
| 105 | + return e.altKey == shortcutKey.altKey && |
| 106 | + e.ctrlKey == shortcutKey.ctrlKey && |
| 107 | + e.shiftKey == shortcutKey.shiftKey && |
| 108 | + String.fromCharCode( e.which ).toLowerCase() == shortcutKey.key.toLowerCase() |
| 109 | + } |
| 110 | + |
| 111 | + function shortcutText() { |
| 112 | + var text = ''; |
| 113 | + // TODO: Localize these things (in core, too) |
| 114 | + if ( shortcutKey.ctrlKey ) { |
| 115 | + text += 'Ctrl-'; |
| 116 | + } |
| 117 | + if ( shortcutKey.shiftKey ) { |
| 118 | + text += 'Shift-'; |
| 119 | + } |
| 120 | + if ( shortcutKey.altKey ) { |
| 121 | + text += 'Alt-'; |
| 122 | + } |
| 123 | + text += shortcutKey.key.toUpperCase(); |
| 124 | + return text; |
| 125 | + } |
| 126 | + |
| 127 | + function onkeydown( e ) { |
| 128 | + // If the current scheme uses the alt key, ignore keydown for Alt+? combinations |
| 129 | + if ( enabled && currentScheme.extended_keyboard && e.altKey && !e.ctrlKey ) { |
| 130 | + e.stopPropagation(); |
| 131 | + return false; // Not in original code -- does this belong here? |
| 132 | + } else if ( isShortcutKey( e ) ) { |
| 133 | + that.toggle(); |
| 134 | + e.stopPropagation(); |
| 135 | + return false; |
| 136 | + } |
| 137 | + return true; |
| 138 | + } |
| 139 | + |
| 140 | + function onkeypress( e ) { |
| 141 | + if ( !enabled ) { |
| 142 | + return true; |
| 143 | + } |
| 144 | + |
| 145 | + if ( e.which == 8 ) { // Backspace |
| 146 | + // Blank the lookback buffer |
| 147 | + $( this ).data( 'narayam-lookback', '' ); |
| 148 | + return true; |
| 149 | + } |
| 150 | + |
| 151 | + // Leave non-ASCII stuff alone, as well as anything involving |
| 152 | + // Alt (except for extended keymaps), Ctrl and Meta |
| 153 | + if ( e.which < 32 || ( e.altKey && !currentScheme.extended_keyboard ) || e.ctrlKey ) { |
| 154 | + return true; |
| 155 | + } |
| 156 | + |
| 157 | + var $this = $( this ); |
| 158 | + var c = String.fromCharCode( e.which ); |
| 159 | + var pos = $this.textSelection( 'getCaretPosition' ); |
| 160 | + // Get the last few characters before the one the user just typed, |
| 161 | + // to provide context for the transliteration regexes. |
| 162 | + // We need to append c because it hasn't been added to $this.val() yet |
| 163 | + var input = lastNChars( $this.val(), pos, currentScheme.lookbackLength ) + c; |
| 164 | + var lookback = $this.data( 'narayam-lookback' ); |
| 165 | + var replacement = transliterate( input, lookback, e.altKey ); |
| 166 | + |
| 167 | + // Update the lookback buffer |
| 168 | + lookback += c; |
| 169 | + if ( lookback.length > currentScheme.lookbackLength ) { |
| 170 | + // The buffer is longer than needed, truncate it at the front |
| 171 | + lookback = lookback.substring( lookback.length - currentScheme.lookbackLength ); |
| 172 | + } |
| 173 | + $this.data( 'narayam-lookback', lookback ); |
| 174 | + |
| 175 | + // textSelection() magic is expensive, so we avoid it as much as we can |
| 176 | + if ( replacement == input ) { |
| 177 | + return true; |
| 178 | + } |
| 179 | + // Drop a common prefix, if any |
| 180 | + // TODO: Profile this, see if it's any faster |
| 181 | + var divergingPos = firstDivergence( input, replacement ); |
| 182 | + input = input.substring( divergingPos ); |
| 183 | + replacement = replacement.substring( divergingPos ); |
| 184 | + |
| 185 | + // Select and replace the text |
| 186 | + $this.textSelection( 'setSelection', { |
| 187 | + 'start': pos - input.length + 1, |
| 188 | + 'end': pos |
| 189 | + } ); |
| 190 | + $this.textSelection( 'encapsulateSelection', { |
| 191 | + 'peri': replacement, |
| 192 | + 'replace': true, |
| 193 | + 'selectPeri': false |
| 194 | + } ); |
| 195 | + |
| 196 | + e.stopPropagation(); |
| 197 | + return false; |
| 198 | + } |
| 199 | + |
| 200 | + function updateSchemeFromSelect() { |
| 201 | + var scheme = $( this ).val(); |
| 202 | + that.setScheme( scheme ); |
| 203 | + $.cookie( 'narayam-scheme', scheme, { 'path': '/', 'expires': 30 } ); |
| 204 | + } |
| 205 | + |
| 206 | + /* Public functions */ |
| 207 | + |
| 208 | + /** |
| 209 | + * Add more inputs to apply Narayam to |
| 210 | + * @param inputs A jQuery object holding one or more input or textarea elements, |
| 211 | + * or an array of DOM elements, or a single DOM element, or a selector |
| 212 | + */ |
| 213 | + this.addInputs = function( inputs ) { |
| 214 | + var $newInputs = $( inputs ); |
| 215 | + $inputs = $inputs.add( $newInputs ); |
| 216 | + $newInputs |
| 217 | + .bind( 'keydown.narayam', onkeydown ) |
| 218 | + .bind( 'keypress.narayam', onkeypress ) |
| 219 | + .data( 'narayam-lookback', '' ); |
| 220 | + if ( enabled ) { |
| 221 | + $newInputs.addClass( 'narayam-input' ); |
| 222 | + } |
| 223 | + }; |
| 224 | + |
| 225 | + this.enable = function() { |
| 226 | + if ( !enabled && currentScheme !== null ) { |
| 227 | + $inputs.addClass( 'narayam-input' ); |
| 228 | + $.cookie( 'narayam-enabled', '1', { 'path': '/', 'expires': 30 } ); |
| 229 | + $( '#narayam-toggle' ).attr( 'checked', true ); |
| 230 | + enabled = true; |
| 231 | + } |
| 232 | + }; |
| 233 | + |
| 234 | + this.disable = function() { |
| 235 | + if ( enabled ) { |
| 236 | + $inputs.removeClass( 'narayam-input' ); |
| 237 | + $.cookie( 'narayam-enabled', '0', { 'path': '/', 'expires': 30 } ); |
| 238 | + $( '#narayam-toggle' ).attr( 'checked', false ); |
| 239 | + enabled = false; |
| 240 | + } |
| 241 | + }; |
| 242 | + |
| 243 | + this.toggle = function() { |
| 244 | + if ( enabled ) { |
| 245 | + that.disable(); |
| 246 | + } else { |
| 247 | + that.enable(); |
| 248 | + } |
| 249 | + }; |
| 250 | + |
| 251 | + /** |
| 252 | + * Add a transliteration scheme. Schemes whose name is not in |
| 253 | + * wgNarayamAvailableSchemes will be ignored. |
| 254 | + * @param name Name of the scheme, must be unique |
| 255 | + * @param data Object with scheme data |
| 256 | + * @return True if added, false if not |
| 257 | + */ |
| 258 | + this.addScheme = function( name, data ) { |
| 259 | + if ( name in availableSchemes ) { |
| 260 | + schemes[name] = data; |
| 261 | + return true; |
| 262 | + } else { |
| 263 | + return false; |
| 264 | + } |
| 265 | + }; |
| 266 | + |
| 267 | + this.setScheme = function( name ) { |
| 268 | + if ( name in schemes ) { |
| 269 | + currentScheme = schemes[name]; |
| 270 | + $select.val( name ); |
| 271 | + } |
| 272 | + }; |
| 273 | + |
| 274 | + this.setup = function() { |
| 275 | + // Build scheme dropdown |
| 276 | + $select = $( '<select />' ); |
| 277 | + var haveSchemes = false; |
| 278 | + for ( var scheme in schemes ) { |
| 279 | + $( '<option />' ) |
| 280 | + .val( scheme ) |
| 281 | + .text( mw.msg( schemes[scheme].namemsg ) ) |
| 282 | + .appendTo( $select ); |
| 283 | + haveSchemes = true; |
| 284 | + } |
| 285 | + $select.change( updateSchemeFromSelect ); |
| 286 | + |
| 287 | + if ( !haveSchemes ) { |
| 288 | + // No schemes available, don't show the tool |
| 289 | + return; |
| 290 | + } |
| 291 | + |
| 292 | + // Build enable/disable checkbox and label |
| 293 | + var $checkbox = $( '<input type="checkbox" id="narayam-toggle" />' ); |
| 294 | + $checkbox |
| 295 | + .attr( 'title', mw.msg( 'narayam-checkbox-tooltip' ) ) |
| 296 | + .click( that.toggle ); |
| 297 | + |
| 298 | + var helppage = mw.msg( 'narayam-help-page' ); |
| 299 | + var $label = $( '<label for="narayam-toggle" />' ); |
| 300 | + $label |
| 301 | + .text( mw.msg( 'narayam-toggle-ime', shortcutText() ) ) |
| 302 | + .attr( 'title', mw.msg( 'narayam-checkbox-tooltip' ) ); |
| 303 | + if ( helppage ) { |
| 304 | + // Link to the help page |
| 305 | + $label.wrapInner( $( '<a />' ).attr( 'href', mw.util.wikiGetlink( helppage ) ) ); |
| 306 | + } |
| 307 | + |
| 308 | + var $checkboxAndLabel = $( '<span />' ) |
| 309 | + .addClass( 'narayam-toggle-wrapper' ) |
| 310 | + .append( $checkbox ) |
| 311 | + .append( $label ); |
| 312 | + var $spanWithEverything = $( '<span />' ) |
| 313 | + .addClass( 'narayam-wrapper' ) |
| 314 | + .append( $select ) |
| 315 | + .append( $checkboxAndLabel ); |
| 316 | + |
| 317 | + // Put the dropdown and the checkbox at the beginning of the |
| 318 | + // search form. This seems to be the most reliable way across skins. |
| 319 | + $( '#searchform' ).prepend( $spanWithEverything ); |
| 320 | + |
| 321 | + // Restore state from cookies |
| 322 | + var savedScheme = $.cookie( 'narayam-scheme' ); |
| 323 | + if ( savedScheme && savedScheme in schemes ) { |
| 324 | + that.setScheme( savedScheme ); |
| 325 | + } else { |
| 326 | + $select.change(); |
| 327 | + } |
| 328 | + var enabledCookie = $.cookie( 'narayam-enabled' ); |
| 329 | + if ( enabledCookie == '1' || ( mw.config.get( 'wgNarayamEnableByDefault' ) && enabledCookie !== '0' ) ) { |
| 330 | + that.enable(); |
| 331 | + } |
| 332 | + }; |
| 333 | + |
| 334 | +} )(); |
| 335 | + |
| 336 | +} )( jQuery ); |
Property changes on: trunk/extensions/Narayam/ext.narayam.core.js |
___________________________________________________________________ |
Added: svn:eol-style |
1 | 337 | + native |
Index: trunk/extensions/Narayam/ext.narayam.rules.ml-inscript.js |
— | — | @@ -0,0 +1,82 @@ |
| 2 | +/** |
| 3 | + * Inscript regular expression rules table for Malayalam |
| 4 | + * @author Junaid P V ([[user:Junaidpv]]) |
| 5 | + * @date 2010-09-08 |
| 6 | + * License: GPLv3 |
| 7 | + */ |
| 8 | +var rules = [ |
| 9 | +['`', '','ൊ'], |
| 10 | +['~', '','ഓ'], |
| 11 | +['_', '','ഃ'], |
| 12 | +['=', '','ൃ'], |
| 13 | +['\\+', '','ഋ'], |
| 14 | +['\\\\', '','\u200C'], |
| 15 | +['q', '','ൗ'], |
| 16 | +['Q', '','ഔ'], |
| 17 | +['w', '','ൈ'], |
| 18 | +['W', '','ഐ'], |
| 19 | +['e', '','ാ'], |
| 20 | +['E', '','ആ'], |
| 21 | +['r', '','ീ'], |
| 22 | +['R', '','ഈ'], |
| 23 | +['t', '','ൂ'], |
| 24 | +['T', '','ഊ'], |
| 25 | +['y', '','ബ'], |
| 26 | +['Y', '','ഭ'], |
| 27 | +['u', '','ഹ'], |
| 28 | +['U', '','ങ'], |
| 29 | +['i', '','ഗ'], |
| 30 | +['I', '','ഘ'], |
| 31 | +['o', '','ദ'], |
| 32 | +['O', '','ധ'], |
| 33 | +['p', '','ജ'], |
| 34 | +['P', '','ഝ'], |
| 35 | +['\\[', '','ഡ'], |
| 36 | +['\\{', '','ഢ'], |
| 37 | +['\\]', '','\u200d'], |
| 38 | +['\\}', '','ഞ'], |
| 39 | +['a', '','ോ'], |
| 40 | +['A', '','ഓ'], |
| 41 | +['s', '','േ'], |
| 42 | +['S', '','ഏ'], |
| 43 | +['d', '','്'], |
| 44 | +['D', '','അ'], |
| 45 | +['f', '','ി'], |
| 46 | +['F', '','ഇ'], |
| 47 | +['g', '','ു'], |
| 48 | +['G', '','ഉ'], |
| 49 | +['h', '','പ'], |
| 50 | +['H', '','ഫ'], |
| 51 | +['j', '','ര'], |
| 52 | +['J', '','റ'], |
| 53 | +['k', '','ക'], |
| 54 | +['K', '','ഖ'], |
| 55 | +['l', '','ത'], |
| 56 | +['L', '','ഥ'], |
| 57 | +[';', '','ച'], |
| 58 | +[':', '','ഛ'], |
| 59 | +['\'', '','ട'], |
| 60 | +['"', '','ഠ'], |
| 61 | +['z', '','െ'], |
| 62 | +['Z', '','എ'], |
| 63 | +['x', '','ം'], |
| 64 | +['c', '','മ'], |
| 65 | +['C', '','ണ'], |
| 66 | +['v', '','ന'], |
| 67 | +['V', '', 'ഒ'], |
| 68 | +['b', '','വ'], |
| 69 | +['B', '','ഴ'], |
| 70 | +['n', '','ല'], |
| 71 | +['N', '','ള'], |
| 72 | +['m', '','സ'], |
| 73 | +['M', '','ശ'], |
| 74 | +['<', '','ഷ'], |
| 75 | +['/', '','യ'] |
| 76 | +]; |
| 77 | + |
| 78 | +jQuery.narayam.addScheme( 'ml-inscript', { |
| 79 | + 'namemsg': 'narayam-ml-inscript', |
| 80 | + 'extended_keyboard': false, |
| 81 | + 'lookbackLength': 0, |
| 82 | + 'rules': rules |
| 83 | +} ); |
Property changes on: trunk/extensions/Narayam/ext.narayam.rules.ml-inscript.js |
___________________________________________________________________ |
Added: svn:eol-style |
1 | 84 | + native |
Index: trunk/extensions/Narayam/ext.narayam.rules.sa.js |
— | — | @@ -0,0 +1,163 @@ |
| 2 | +/** |
| 3 | + * Trasliteration regular expression rules table for Sanskrit |
| 4 | + * @author Junaid P V ([[user:Junaidpv]]) |
| 5 | + * @date 2010-10-12 |
| 6 | + * @credits With help from Naveen Shankar |
| 7 | + * License: GPLv3, CC-BY-SA 3.0 |
| 8 | + */ |
| 9 | + |
| 10 | + // Normal rules |
| 11 | +var rules = [ |
| 12 | +['क्h','c','च्'], |
| 13 | +['\\\\([A-Za-z\\>_~\\.0-9])','\\\\','$1'], |
| 14 | + |
| 15 | +['([क-ह]़?)्a', '','$1'], |
| 16 | +['([क-ह]़?)्A', '','$1ा'], |
| 17 | +['([क-ह]़?)a', '','$1ा'], |
| 18 | +['([क-ह]़?)्i', '','$1ि'], |
| 19 | +['([क-ह]़?)(्I|िi|ॆe)', '','$1ी'], |
| 20 | +['([क-ह]़?)्u', '','$1ु'], |
| 21 | +['([क-ह]़?)(ुu|्U|ॊo)', '','$1ू'], |
| 22 | +['([क-ह]़?)्R', '','$1ृ'], |
| 23 | +['([क-ह]़?)ृR', '','$1ॄ'], |
| 24 | +['([क-ह]़?)्ळ्l', '','$1ॢ'], |
| 25 | +['([क-ह]़?)ॢl', '','$1ॣ'], |
| 26 | +['([क-ह]़?)ॆ\\^', '','$1ॅ'], |
| 27 | +['([क-ह]़?)्e', '','$1ॆ'], |
| 28 | +['([क-ह]़?)्E', '','$1े'], |
| 29 | +['([क-ह]़?)ॊ\\^', '','$1ॉ'], |
| 30 | +['([क-ह]़?)i', '','$1ै'], |
| 31 | +['([क-ह]़?)्o', '','$1ॊ'], |
| 32 | +['([क-ह]़?)्O', '','$1ो'], |
| 33 | +['([क-ह]़?)u', '','$1ौ'], |
| 34 | +['([क-ह]़?)ृa', '','$1्ऱ'], |
| 35 | +['([क-ह]़?)ृA', '','$1्ऱा'], |
| 36 | +['([क-ह]़?)ृi', '','$1्ऱि'], |
| 37 | +['([क-ह]़?)ृI', '','$1्ऱी'], |
| 38 | +['([क-ह]़?)ृu', '','$1्ऱु'], |
| 39 | +['([क-ह]़?)ृU', '','$1्ऱू'], |
| 40 | +['([क-ह]़?)ृ\\^', '','$1्ऱॅ'], |
| 41 | +['([क-ह]़?)ृe', '','$1्ऱॆ'], |
| 42 | +['([क-ह]़?)ृE', '','$1्ऱे'], |
| 43 | +['([क-ह]़?)ृo', '','$1्ऱॊ'], |
| 44 | +['([क-ह]़?)ृO', '','$1्ऱो'], |
| 45 | +['([क-ह]़?)ृ\\~', '','$1्ऱ्'], |
| 46 | +['([क-ह])्\\`', '','$1़्'], |
| 47 | + |
| 48 | +['अa', '','आ'], |
| 49 | +['(ऒo|उu)', '','ऊ'], |
| 50 | +['ऎ\\^', '','ऍ'], |
| 51 | +['अi', '','ऐ'], |
| 52 | +['अ\\^', '','ॲ'], |
| 53 | +['(इi|ऎe)', '','ई'], |
| 54 | +['ऒ\\^', '','ऑ'], |
| 55 | +['अu', '','औ'], |
| 56 | +['ऋR', '','ॠ'], |
| 57 | +['ळ्l', '','ऌ'], |
| 58 | +['ऌl', '','ॡ'], |
| 59 | +['ं\\^', '','ँ'], |
| 60 | +['ंm', '','ँ'], |
| 61 | +['ओM', '','ॐ'], |
| 62 | + |
| 63 | +['क्h', '','ख्'], |
| 64 | +['ग्h', '','घ्'], |
| 65 | +['न्g', '','ङ्'], |
| 66 | +['च्h', '','छ्'], |
| 67 | +['ज्h', '','झ्'], |
| 68 | +['न्j', '','ञ्'], |
| 69 | +['ट्h', '','ठ्'], |
| 70 | +['ड्h', '','ढ्'], |
| 71 | +['त्h', '','थ्'], |
| 72 | +['द्h', '','ध्'], |
| 73 | +['प्h', '','फ्'], |
| 74 | +['ब्h', '','भ्'], |
| 75 | +['ऋa', '','ऱ'], |
| 76 | +['ऋA', '','ऱा'], |
| 77 | +['ऋi', '','ऱि'], |
| 78 | +['ऋI', '','ऱी'], |
| 79 | +['ऋu', '','ऱु'], |
| 80 | +['ऋU', '','ऱू'], |
| 81 | +['ऋ\\^', '','ऱॅ'], |
| 82 | +['ऋe', '','ऱॆ'], |
| 83 | +['ऋE', '','ऱे'], |
| 84 | +['ऋo', '','ऱॊ'], |
| 85 | +['ऋO', '','ऱो'], |
| 86 | +['ऋ\\~', '','ऱ्'], |
| 87 | + |
| 88 | +['स्h', '','ष्'], |
| 89 | +['क़्h', '','ख़्'], |
| 90 | +['ज़्h', '','ऴ्'], |
| 91 | +['।\\.', '','॥'], |
| 92 | + |
| 93 | +['a', '','अ'], |
| 94 | +['b', '','ब्'], |
| 95 | +['c', '','क्'], |
| 96 | +['d', '','द्'], |
| 97 | +['e', '','ऎ'], |
| 98 | +['(f|F)', '','फ़्'], |
| 99 | +['g', '','ग्'], |
| 100 | +['h', '','ह्'], |
| 101 | +['i', '','इ'], |
| 102 | +['j', '','ज्'], |
| 103 | +['k', '','क्'], |
| 104 | +['l', '','ल्'], |
| 105 | +['m', '','म्'], |
| 106 | +['n', '','न्'], |
| 107 | +['o', '','ऒ'], |
| 108 | +['p', '','प्'], |
| 109 | +['q', '','क़्'], |
| 110 | +['r', '','र्'], |
| 111 | +['s', '','स्'], |
| 112 | +['t', '','त्'], |
| 113 | +['u', '','उ'], |
| 114 | +['(v|w)', '','व्'], |
| 115 | +['x', '','क्ष्'], |
| 116 | +['y', '','य्'], |
| 117 | +['(z|Z)', '','ज़्'], |
| 118 | +['A', '','आ'], |
| 119 | +['B', '','ब्ब्'], |
| 120 | +['C', '','क्क्'], |
| 121 | +['D', '','ड्'], |
| 122 | +['E', '','ए'], |
| 123 | +//'F', '','फ्'], |
| 124 | +['G', '','ग्ग्'], |
| 125 | +['H', '','ः'], |
| 126 | +['I', '','ई'], |
| 127 | +['J', '','ज्ज्'], |
| 128 | +['K', '','क्क्'], |
| 129 | +['L', '','ळ्'], |
| 130 | +['M', '','ं'], |
| 131 | +['N', '','ण्'], |
| 132 | +['O', '','ओ'], |
| 133 | +['P', '','प्प्'], |
| 134 | +//'Q', '','अ'], |
| 135 | +['R', '','ऋ'], |
| 136 | +['S', '','श्'], |
| 137 | +['T', '','ट्'], |
| 138 | +['U', '','ऊ'], |
| 139 | +['(V|W)', '','व्व्'], |
| 140 | +['X', '','क्ष्'], |
| 141 | +['Y', '','य्य्'], |
| 142 | +//'z', '','अ' |
| 143 | +['0', '','०'], |
| 144 | +['1', '','१'], |
| 145 | +['2', '','२'], |
| 146 | +['3', '','३'], |
| 147 | +['4', '','४'], |
| 148 | +['5', '','५'], |
| 149 | +['6', '','६'], |
| 150 | +['7', '','७'], |
| 151 | +['8', '','८'], |
| 152 | +['9', '','९'], |
| 153 | +['~', '','्'], |
| 154 | +['\\.', '','।'], |
| 155 | +['//', '','ऽ'], |
| 156 | +['\\`', '','़'] |
| 157 | +]; |
| 158 | + |
| 159 | +jQuery.narayam.addScheme( 'sa', { |
| 160 | + 'namemsg': 'narayam-sa', |
| 161 | + 'extended_keyboard': false, |
| 162 | + 'lookbackLength': 2, |
| 163 | + 'rules': rules |
| 164 | +} ); |
Property changes on: trunk/extensions/Narayam/ext.narayam.rules.sa.js |
___________________________________________________________________ |
Added: svn:eol-style |
1 | 165 | + native |
Index: trunk/extensions/Narayam/ext.narayam.rules.bn-avro.js |
— | — | @@ -0,0 +1,196 @@ |
| 2 | +/** |
| 3 | + * Avro layout regular expression rules table for Bengali script |
| 4 | + * @author Junaid P V ([[user:Junaidpv]]) |
| 5 | + * @date 2010-12-05 |
| 6 | + * License: GPLv3, CC-BY-SA 3.0 |
| 7 | + */ |
| 8 | + |
| 9 | +var rules = [ |
| 10 | +['([ক-হড়ঢ়য়])্?ররi','[^o`]', '$1ৃ'], |
| 11 | +['ররi','[^o`]', 'ঋ'], |
| 12 | + |
| 13 | +['ঙহo', '', 'ঙ্ঘ'], |
| 14 | + |
| 15 | +['([ক-হড়ঢ়য়])াZ', '[^o`]', '$1্যা'], |
| 16 | + |
| 17 | +['(([ক-হড়ঢ়য়])|য়)o','[^o`]', '$1'], // য় cannot be included in the range, why? everywhere else it is OK! |
| 18 | +['([ক-হড়ঢ়য়])a','[^o`]', '$1া'], |
| 19 | +['([ক-হড়ঢ়য়])i','[^o`]', '$1ি'], |
| 20 | +['([ক-হড়ঢ়য়])(I|েe)','[^o`]', '$1ী'], |
| 21 | +['([ক-হড়ঢ়য়])u','[^o`]', '$1ু'], |
| 22 | +['([ক-হড়ঢ়য়])U','[^o`]', '$1ূ'], |
| 23 | +['([ক-হড়ঢ়য়])o','[o`]', '$1ু'], |
| 24 | +['([ক-হড়ঢ়য়])e','[^o`]', '$1ে'], |
| 25 | +['([ক-হড়ঢ়য়])োI','[^o`]', '$1ৈ'], |
| 26 | +['([ক-হড়ঢ়য়])O','[^o`]', '$1ো'], |
| 27 | +['([ক-হড়ঢ়য়])োU','[^o`]', '$1ৌ'], |
| 28 | + |
| 29 | +['([ক-হড়ঢ়য়][িুেো]|[এইওউ])a','[^o`]', '$1য়া'], |
| 30 | +['([ক-হড়ঢ়য়][াে]|[আএ])o', '[^o`]', '$1ও'], |
| 31 | +//'চচh','[^o`]', 'চ্চ'], |
| 32 | + |
| 33 | +['([কঙলষস])(k|K)','[^o`]','$1্ক'], |
| 34 | +['([ঙদল])(g|G)','[^o`]','$1্গ'], |
| 35 | +['গg','[^o`]','জ্ঞ'], |
| 36 | +['([চশ])c','[^o`]','$1্চ'], |
| 37 | +['([জঞব])j','[^o`]','$1্জ'], |
| 38 | +['নj','[^o`]','ঞ্জ'], |
| 39 | +['([কটণনপলষস])T','[^o`]','$1্ট'], |
| 40 | +['([ডণনল])D','[^o`]','$1্ড'], |
| 41 | +['([গষহ])N','[^o`]','$1্ণ'], |
| 42 | +['([কতনপশসহ])t','[^o`]','$1্ত'], |
| 43 | +['([দনব])d','[^o`]','$1্দ'], |
| 44 | +['([গঘণতধনপমশসহ])n','[^o`]','$1্ন'], |
| 45 | +['([পমলষস])p','[^o`]','$1্প'], |
| 46 | +['([স])f', '[^o`]', '$1্ফ'], |
| 47 | +['([বমল])b','[^o`]','$1্ব'], |
| 48 | +['([দম])(v|V)','[^o`]','$1্ভ'], |
| 49 | +['([কগঙটণতদধনমলশষসহ])m','[^o`]','$1্ম'], |
| 50 | +['([ক-ঘচ-ঝট-যলশ-হড়ঢ়য়])r','[^o`]','$1্র'], |
| 51 | +['([কগপ-বমলশসহ])l','[^o`]','$1্ল'], |
| 52 | +['([কনপ])s','[^o`]','$1্স'], |
| 53 | +['([ক-হড়ঢ়য়])w','[^o`]','$1্ব'], |
| 54 | +['([ক-হড়ঢ়য়])y','[^o`]','$1্য'], |
| 55 | +['নc','[^o`]','ঞ্চ'], |
| 56 | + |
| 57 | +['ত`','`' ,'ৎ'], |
| 58 | + |
| 59 | +['ক্ক(h|H)','[^o`]','ক্ষ'], |
| 60 | +['কশ(h|H)','[^o`]','ক্ষ'], |
| 61 | +//'([অ-ঔা-ৌ])ররk','[^o]','$1র্ক'], |
| 62 | + |
| 63 | +['ররk','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ক'], |
| 64 | +['ররg','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্গ'], |
| 65 | +['ররc','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্চ'], |
| 66 | +['ররj','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্জ'], |
| 67 | +['ররT','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ট'], |
| 68 | +['ররD','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ড'], |
| 69 | +['ররN','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ণ'], |
| 70 | +['ররt','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ত'], |
| 71 | +['ররd','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্দ'], |
| 72 | +['ররn','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ন'], |
| 73 | +['ররp','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্প'], |
| 74 | +['ররf','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ফ'], |
| 75 | +['ররb','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ব'], |
| 76 | +['ররv','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ভ'], |
| 77 | +['ররm','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ম'], |
| 78 | +['ররz','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্য'], |
| 79 | +['ররl','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ল'], |
| 80 | +['ররS','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্শ'], |
| 81 | +['ররs','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্স'], |
| 82 | +['ররh','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্হ'], |
| 83 | +['ররR','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্ড়'], |
| 84 | +['রর(y|Y)','(o|a|i|I|u|U|e|O|OI|OU|rri)rr','র্য়'], |
| 85 | + |
| 86 | +['ংo', '', 'ঙ্গ'], |
| 87 | +['ংi', '', 'ঙ্গি'], |
| 88 | +['ংI', '', 'ঙ্গী'], |
| 89 | +['(ংu|ঙ্গo)', '', 'ঙ্গু'], |
| 90 | +['ংU', '', 'ঙ্গূ'], |
| 91 | +['ং', '', 'ঙ্গি'], |
| 92 | +['ং', '', 'ঙ্গি'], |
| 93 | + |
| 94 | +['শ(h|H)','S', 'ষ'], |
| 95 | + |
| 96 | +['অo','[^`]', 'উ'], |
| 97 | +['এe','[^o`]', 'ঈ'], |
| 98 | + |
| 99 | +['ক(h|H)','[^o`]', 'খ'], |
| 100 | +['গ(h|H)','[^o`]', 'ঘ'], |
| 101 | +['ণg','[^o`]', 'ঙ'], |
| 102 | +['চ(h|H)','[^o`]', 'ছ'], |
| 103 | +['জ(h|H)','[^o`]', 'ঝ'], |
| 104 | +['ণG','[^o`]', 'ঞ'], |
| 105 | +['ট(h|H)','[^o`]', 'ঠ'], |
| 106 | +['ড(h|H)','[^o`]', 'ঢ'], |
| 107 | +['ত(h|H)','[^o`]', 'থ'], |
| 108 | +['দ(h|H)','[^o`]', 'ধ'], |
| 109 | +['প(h|H)','[^o`]', 'ফ'], |
| 110 | +['ব(h|H)','[^o`]', 'ভ'], |
| 111 | +['(স(h|H))','[^o`]', 'শ'], |
| 112 | +['ড়(h|H)','[^o`]', 'ঢ়'], |
| 113 | +['ত্`','[^o`]', 'ৎ'], |
| 114 | +['নg','[^o`]', 'ং'], |
| 115 | +['ঃ`','[^o`]', ':'], |
| 116 | +['ররi','[^o`]', 'ঋ'], |
| 117 | +['ওI','[^o`]', 'ঐ'], |
| 118 | +['ওU','[^o`]', 'ঔ'], |
| 119 | + |
| 120 | +['আ`', '', 'া'], |
| 121 | +['ই`', '', 'ি'], |
| 122 | +['ঈ`', '', 'ী'], |
| 123 | +['উ`', '', 'ু'], |
| 124 | +['ঊ`', '', 'ূ'], |
| 125 | +['এ`', '', 'ে'], |
| 126 | +['আ`', '', 'া'], |
| 127 | +['আ`', '', 'া'], |
| 128 | +['আ`', '', 'া'], |
| 129 | +['আ`', '', 'া'], |
| 130 | +['আ`', '', 'া'], |
| 131 | +['আ`', '', 'া'], |
| 132 | + |
| 133 | +['([kKqQ])','' ,'ক'], |
| 134 | +['(g|G)','' ,'গ'], |
| 135 | +['(c|C)','' ,'চ'], |
| 136 | +['(j|J)','' ,'জ'], |
| 137 | +['T','' ,'ট'], |
| 138 | +['D','' ,'ড'], |
| 139 | +['N','' ,'ণ'], |
| 140 | +['t','' ,'ত'], |
| 141 | +['d','' ,'দ'], |
| 142 | +['n','' ,'ন'], |
| 143 | +['(p|P)','' ,'প'], |
| 144 | +['f','' ,'ফ'], |
| 145 | +['(b|B)','' ,'ব'], |
| 146 | +['(v|V)','' ,'ভ'], |
| 147 | +['(m|M)','' ,'ম'], |
| 148 | +['z','' ,'য'], |
| 149 | +['r','' ,'র'], |
| 150 | +['(l|L)','' ,'ল'], |
| 151 | +['S','' ,'শ'], |
| 152 | +['s','' ,'স'], |
| 153 | +['(h|H)','' ,'হ'], |
| 154 | +['R','' ,'ড়'], |
| 155 | +['w', '', 'ও'], |
| 156 | +['x', '', 'ক্স'], |
| 157 | +['(y|Y)','' ,'য়'], |
| 158 | + |
| 159 | +['Z','' ,'্য'], |
| 160 | + |
| 161 | +['o','' ,'অ'], |
| 162 | +['(a|A)','' ,'আ'], |
| 163 | +['i','' ,'ই'], |
| 164 | +['I','' ,'ঈ'], |
| 165 | +['u','' ,'উ'], |
| 166 | +['U','' ,'ঊ'], |
| 167 | +['(e|E)','' ,'এ'], |
| 168 | +['O','' ,'ও'], |
| 169 | + |
| 170 | +['0','' ,'০'], |
| 171 | +['1','' ,'১'], |
| 172 | +['2','' ,'২'], |
| 173 | +['3','' ,'৩'], |
| 174 | +['4','' ,'৪'], |
| 175 | +['5','' ,'৫'], |
| 176 | +['6','' ,'৬'], |
| 177 | +['7','' ,'৭'], |
| 178 | +['8','' ,'৮'], |
| 179 | +['9','' ,'৯'], |
| 180 | + |
| 181 | +['\\\\\\.','' ,'.'], |
| 182 | + |
| 183 | +[',,','' ,'্'], |
| 184 | +['\\:','' ,'ঃ'], |
| 185 | +['\\^','' ,'ঁ'], |
| 186 | +['\\.','' ,'।'], |
| 187 | +['\\$','' ,'৳'], |
| 188 | +['ঃ`','' ,':'], |
| 189 | +['`','' ,''] |
| 190 | +]; |
| 191 | + |
| 192 | +jQuery.narayam.addScheme( 'bn-avro', { |
| 193 | + 'namemsg': 'narayam-bn-avro', |
| 194 | + 'extended_keyboard': false, |
| 195 | + 'lookbackLength': 5, |
| 196 | + 'rules': rules |
| 197 | +} ); |
Property changes on: trunk/extensions/Narayam/ext.narayam.rules.bn-avro.js |
___________________________________________________________________ |
Added: svn:eol-style |
1 | 198 | + native |
Index: trunk/extensions/Narayam/ext.narayam.rules.ta.js |
— | — | @@ -0,0 +1,110 @@ |
| 2 | +/** |
| 3 | + * Trasliteration regular expression rules table for Tamil |
| 4 | + * @author Junaid P V ([[user:Junaidpv]]) |
| 5 | + * @date 2010-11-21 |
| 6 | + * License: GPLv3, CC-BY-SA 3.0 |
| 7 | + */ |
| 8 | + |
| 9 | +// Normal rules |
| 10 | +var rules = [ |
| 11 | +['ச்h','h','ச்ஹ்',], |
| 12 | +['ழ்h','h','ழ்ஹ்',], |
| 13 | + |
| 14 | + //'(ஸ்ரிi|ஸ்ர்I)', '','', |
| 15 | + |
| 16 | +['([க-ஹ])்a', '','$1'], |
| 17 | +['([க-ஹ])(்A|a)', '','$1ா'], |
| 18 | +['([க-ஹ])்i', '','$1ி'], |
| 19 | +['([க-ஹ])(்I|ிi)', '','$1ீ'], |
| 20 | +['([க-ஹ])்u', '','$1ு'], |
| 21 | +['([க-ஹ])(்U|ுu)', '','$1ூ'], |
| 22 | +['([க-ஹ])்e', '','$1ெ'], |
| 23 | +['([க-ஹ])(்E|ெe)', '','$1ே'], |
| 24 | +['([க-ஹ])i', '','$1ை'], |
| 25 | +['([க-ஹ])்o', '','$1ொ'], |
| 26 | +['([க-ஹ])(்O|ொo)', '','$1ோ'], |
| 27 | +['([க-ஹ])u', '','$1ௌ'], |
| 28 | + |
| 29 | +['([அ-ஹ][ெ-்]?)n', '','$1ன்'], |
| 30 | + |
| 31 | +['அa', '','ஆ'], |
| 32 | +['இi', '','ஈ'], |
| 33 | +['உu', '','ஊ'], |
| 34 | +['எe', '','ஏ'], |
| 35 | +['அi', '','ஐ'], |
| 36 | +['ஒo', '','ஓ'], |
| 37 | +['அu', '','ஔ'], |
| 38 | + |
| 39 | +['(ந்|ன்)g', '','ங்'], |
| 40 | +['(ந்|ன்)j', '','ஞ்'], |
| 41 | +['ச்h', '','ச்'], |
| 42 | +['ழ்h', '','ழ்'], |
| 43 | +['ட்h', '','த்'], |
| 44 | +['ஸ்h', '','ஷ்'], |
| 45 | + |
| 46 | +['a', '','அ'], |
| 47 | +['c', '','ச்'], |
| 48 | +['d', '','ட்'], |
| 49 | +['e', '','எ'], |
| 50 | +['h', '','ஹ்'], |
| 51 | +['i', '','இ'], |
| 52 | +['j', '','ஜ்'], |
| 53 | +['k', '','க்'], |
| 54 | +['l', '','ல்'], |
| 55 | +['m', '','ம்'], |
| 56 | +['n', '','ந்'], |
| 57 | +['o', '','ஒ'], |
| 58 | +['p', '','ப்'], |
| 59 | +['q', '','ஃ'], |
| 60 | +['r', '','ர்'], |
| 61 | +['s', '','ச்'], |
| 62 | +['t', '','ட்'], |
| 63 | +['u', '','உ'], |
| 64 | +['v', '','வ்'], |
| 65 | +['w', '','ந்'], |
| 66 | +['y', '','ய்'], |
| 67 | +['z', '','ழ்'], |
| 68 | +['A', '','ஆ'], |
| 69 | + |
| 70 | +['C', '','க்க்'], |
| 71 | +['E', '','ஏ'], |
| 72 | +['H', '','ஃ'], |
| 73 | +['I', '','ஈ'], |
| 74 | +['J', '','ஜ்ஜ்'], |
| 75 | +['K', '','க்'], |
| 76 | +['L', '','ள்'], |
| 77 | +['M', '','ம்ம்'], |
| 78 | +['N', '','ண்'], |
| 79 | +['O', '','ஓ'], |
| 80 | +['P', '','ப்ப்'], |
| 81 | +['R', '','ற்'], |
| 82 | +['S', '','ஸ்'], |
| 83 | +['T', '','ட்'], |
| 84 | +['U', '','ஊ'], |
| 85 | +['(V|W)', '','வ்வ்'], |
| 86 | +['Y', '','ய்ய்'], |
| 87 | +['Z', '','ஶ்'], |
| 88 | + |
| 89 | +['~', '','்'], |
| 90 | + |
| 91 | +['\\\\0', '','\u0be6'], |
| 92 | +['\\\\1', '','௧'], |
| 93 | +['\\\\2', '','௨'], |
| 94 | +['\\\\3', '','௩'], |
| 95 | +['\\\\4', '','௪'], |
| 96 | +['\\\\5', '','௫'], |
| 97 | +['\\\\6', '','௬'], |
| 98 | +['\\\\7', '','௭'], |
| 99 | +['\\\\8', '','௮'], |
| 100 | +['\\\\9', '','௯'], |
| 101 | +['10\\\\', '','\u0BF0'], |
| 102 | +['100\\\\', '','\u0BF1'], |
| 103 | +['1000\\\\', '','\u0BF2'] |
| 104 | +]; |
| 105 | + |
| 106 | +jQuery.narayam.addScheme( 'ta', { |
| 107 | + 'namemsg': 'narayam-ta', |
| 108 | + 'extended_keyboard': false, |
| 109 | + 'lookbackLength': 1, |
| 110 | + 'rules': rules |
| 111 | +} ); |
Property changes on: trunk/extensions/Narayam/ext.narayam.rules.ta.js |
___________________________________________________________________ |
Added: svn:eol-style |
1 | 112 | + native |
Index: trunk/extensions/Narayam/ext.narayam.rules.bn-nkb.js |
— | — | @@ -0,0 +1,137 @@ |
| 2 | +/** |
| 3 | + * Regular expression rules table for Bengali National Keyboard |
| 4 | + * @author Junaid P V ([[user:Junaidpv]]) |
| 5 | + * @date 2010-12-13 |
| 6 | + * @credits From the standard developed by Bangladesh Computer Council, |
| 7 | + * Ministry of Science and Information & Communication Technology, Govt. of Bangladesh |
| 8 | + * License: GPLv3, CC-BY-SA 3.0 |
| 9 | + */ |
| 10 | + |
| 11 | +// Normal rules |
| 12 | +var rules = [ |
| 13 | +['1', '', '১'], |
| 14 | +['2', '', '২'], |
| 15 | +['3', '', '৩'], |
| 16 | +['4', '', '৪'], |
| 17 | +['5', '', '৫'], |
| 18 | +['6', '', '৬'], |
| 19 | +['7', '', '৭'], |
| 20 | +['8', '', '৮'], |
| 21 | +['9', '', '৯'], |
| 22 | +['0', '', '০'], |
| 23 | + |
| 24 | +['q', '', 'ঙ'], |
| 25 | +['w', '', 'য'], |
| 26 | +['e', '', 'ড'], |
| 27 | +['r', '', 'প'], |
| 28 | +['t', '', 'ট'], |
| 29 | +['y', '', 'চ'], |
| 30 | +['u', '', 'জ'], |
| 31 | +['i', '', 'হ'], |
| 32 | +['o', '', 'গ'], |
| 33 | +['p', '', 'ড়'], |
| 34 | + |
| 35 | +['a', '', 'ৃ'], |
| 36 | +['s', '', 'ু'], |
| 37 | +['d', '', 'ি'], |
| 38 | +['f', '', 'ব'], |
| 39 | +['g', '', '্'], |
| 40 | +['h', '', 'া'], |
| 41 | +['j', '', 'ক'], |
| 42 | +['k', '', 'ত'], |
| 43 | +['l', '', 'দ'], |
| 44 | + |
| 45 | +['z', '', 'ঁ'], |
| 46 | +['x', '', 'ো'], |
| 47 | +['c', '', 'ে'], |
| 48 | +['v', '', 'র'], |
| 49 | +['b', '', 'ন'], |
| 50 | +['n', '', 'স'], |
| 51 | +['m', '', 'ম'], |
| 52 | + |
| 53 | +['Q', '', 'ং'], |
| 54 | +['W', '', 'য়'], |
| 55 | +['E', '', 'ঢ'], |
| 56 | +['R', '', 'ফ'], |
| 57 | +['T', '', 'ঠ'], |
| 58 | +['Y', '', 'ছ'], |
| 59 | +['U', '', 'ঝ'], |
| 60 | +['I', '', 'ঞ'], |
| 61 | +['O', '', 'ঘ'], |
| 62 | +['P', '', 'ঢ়'], |
| 63 | + |
| 64 | +['A', '', 'ৗ'], |
| 65 | +['S', '', 'ূ'], |
| 66 | +['D', '', 'ী'], |
| 67 | +['F', '', 'ভ'], |
| 68 | +['G', '', '।'], |
| 69 | +['H', '', 'অ'], |
| 70 | +['J', '', 'খ'], |
| 71 | +['K', '', 'থ'], |
| 72 | +['L', '', 'ধ'], |
| 73 | + |
| 74 | +['Z', '', 'ঃ'], |
| 75 | +['X', '', 'ৌ'], |
| 76 | +['C', '', 'ৈ'], |
| 77 | +['V', '', 'ল'], |
| 78 | +['B', '', 'ণ'], |
| 79 | +['N', '', 'ষ'], |
| 80 | +['M', '', 'শ'] |
| 81 | +]; |
| 82 | + |
| 83 | +// Extended layout for National Keyboard. Works in Firefox only |
| 84 | +var rules_x = [ |
| 85 | +['1', '', '৴'], |
| 86 | +['2', '', '৵'], |
| 87 | +['3', '', '৶'], |
| 88 | +['4', '', '৳'], |
| 89 | +['5', '', '৷'], |
| 90 | +['6', '', '৸'], |
| 91 | +['7', '', 'ं'], |
| 92 | +['0', '', '৹'], |
| 93 | +['\\-', '', '\u200C'], |
| 94 | +['\\=', '', '\u200D'], |
| 95 | + |
| 96 | +['q', '', 'ৢ'], |
| 97 | +['w', '', '্য'], |
| 98 | +['e', '', 'ৄ'], |
| 99 | +['i', '', 'ঽ'], |
| 100 | + |
| 101 | +['a', '', 'ঋ'], |
| 102 | +['s', '', 'উ'], |
| 103 | +['d', '', 'ই'], |
| 104 | +['f', '', 'ৰ'], |
| 105 | +['g', '', '॥'], |
| 106 | +['h', '', 'আ'], |
| 107 | +['j', '', ''], |
| 108 | +['k', '', 'ঢ'], |
| 109 | +['l', '', 'ঌ'], |
| 110 | + |
| 111 | +['z', '', '৺'], |
| 112 | +['x', '', 'ও'], |
| 113 | +['c', '', 'এ'], |
| 114 | +['v', '', '্র'], |
| 115 | +['\\.', '', '়'], |
| 116 | + |
| 117 | +['\\$', '', '৲'], |
| 118 | +['\\^', '', ''], |
| 119 | + |
| 120 | +['Q', '', 'ৣ'], |
| 121 | + |
| 122 | +['A', '', 'ৠ'], |
| 123 | +['S', '', 'ঊ'], |
| 124 | +['D', '', 'ঈ'], |
| 125 | +['F', '', 'ৱ'], |
| 126 | +['L', '', 'ৡ'], |
| 127 | + |
| 128 | +['X', '', 'ঔ'], |
| 129 | +['C', '', 'ঐ'] |
| 130 | +]; |
| 131 | + |
| 132 | +jQuery.narayam.addScheme( 'bn-nkb', { |
| 133 | + 'namemsg': 'narayam-bn-nkb', |
| 134 | + 'extended_keyboard': true, |
| 135 | + 'lookbackLength': 0, |
| 136 | + 'rules': rules, |
| 137 | + 'rules_x': rules_x |
| 138 | +} ); |
Property changes on: trunk/extensions/Narayam/ext.narayam.rules.bn-nkb.js |
___________________________________________________________________ |
Added: svn:eol-style |
1 | 139 | + native |
Index: trunk/extensions/Narayam/ext.narayam.rules.ml.js |
— | — | @@ -0,0 +1,335 @@ |
| 2 | +/** |
| 3 | + * Trasliteration regular expression rules table for Malayalam |
| 4 | + * @author Junaid P V ([[user:Junaidpv]]) with extensive advise from Thachan Makan ([[user:Thachan.makan]]) |
| 5 | + * @date 2010-05-19 (update: 2010-12-11) |
| 6 | + * @credits Malayalam Wikimedia Community, especialy Thachan Makan ([[user:Thachan.makan]]) |
| 7 | + * License: GPLv3, CC-BY-SA 3.0 |
| 8 | + */ |
| 9 | + |
| 10 | +// Normal rules |
| 11 | +var rules = [ |
| 12 | +['(\u200c)+a', '', 'അ'], |
| 13 | +['(\u200c)+A', '', 'ആ'], |
| 14 | +['(\u200c)+i', '', 'ഇ'], |
| 15 | +['(\u200c)+u', '', 'ഉ'], |
| 16 | +['(\u200c)+U', '', 'ഊ'], |
| 17 | +['(\u200c)+R', '', 'ഋ'], |
| 18 | +['(\u200c)+e', '', 'എ'], |
| 19 | +['(\u200c)+E', '', 'ഏ'], |
| 20 | +['(\u200c)+I', '', 'ഐ'], |
| 21 | +['(\u200c)+o', '', 'ഒ'], |
| 22 | +['(\u200c)+O', '', 'ഓ'], |
| 23 | +['(\u200c)+H', '', 'ഃ'], |
| 24 | +['ൻൿh','nc','ഞ്ച്'], |
| 25 | +['ൿh','c', 'ച്'], |
| 26 | +['ക്ക്h','cc', 'ച്ച്'], |
| 27 | +['ല്പ്p','lp','ൽപ്പ്'], |
| 28 | + |
| 29 | +['\\\\([A-Za-z\\>_~])','\\\\','$1'], |
| 30 | + |
| 31 | +['([ക-ഹ])്R', '', '$1ൃ'], |
| 32 | +['ന്ന്j', '', 'ഞ്ഞ്'], |
| 33 | +['ന്ന്g', '', 'ങ്ങ്'], |
| 34 | +['റ്റ്h', '', 'ത്'], |
| 35 | +['റ്റ്t', '', 'ട്ട്'], |
| 36 | +['ന്റ്h', '', 'ന്ത്'], |
| 37 | +['([ക-ഹ])്ല്l', 'L', '$1\u0d62'], |
| 38 | +['([ക-ഹ])\u0d62l', '', '$1\u0d63'], |
| 39 | +['([അ-ഊഌഎ-ഐഒ-ഹ])([ഽ-ൂെ-ൌൗ])+R', '', '$1$2റ്'], |
| 40 | +['([ക-ഹ])ൃa', '', '$1്ര'], |
| 41 | +['([ക-ഹ])ൃA', '', '$1്രാ'], |
| 42 | +['([ക-ഹ])ൃi', '', '$1്രി'], |
| 43 | +['([ക-ഹ])ൃI', '', '$1്രീ'], |
| 44 | +['([ക-ഹ])ൃu', '', '$1്രു'], |
| 45 | +['([ക-ഹ])ൃU', '', '$1്രൂ'], |
| 46 | +['([ക-ഹ])ൃe', '', '$1്രെ'], |
| 47 | +['([ക-ഹ])ൃE', '', '$1്രേ'], |
| 48 | +['([ക-ഹ])ൃo', '', '$1്രൊ'], |
| 49 | +['([ക-ഹ])ൃO', '', '$1്രോ'], |
| 50 | +['([ക-ഹ])്(l|L)', '', '$1്ല്'], |
| 51 | +['അa', '', 'ആ'], |
| 52 | +['അi', '', 'ഐ'], |
| 53 | +['അu', '', 'ഔ'], |
| 54 | +['ഇi', '', 'ഈ'], |
| 55 | +['ഉu', '', 'ഊ'], |
| 56 | +['ഊo', '', 'ഊഊ'], |
| 57 | +['ഋR', '', 'ൠ'], |
| 58 | +['ഋa', '', 'റ'], |
| 59 | +['ഋA', '', 'റാ'], |
| 60 | +['ഋi', '', 'റി'], |
| 61 | +['ഋI', '', 'റീ'], |
| 62 | +['ഋu', '', 'റു'], |
| 63 | +['ഋU', '', 'റൂ'], |
| 64 | +['ഋe', '', 'റെ'], |
| 65 | +['ഋE', '', 'റേ'], |
| 66 | +['ഋo', '', 'റൊ'], |
| 67 | +['ഋO', '', 'റോ'], |
| 68 | +['ഋ~', '', 'റ്'], |
| 69 | +['ഌl', '', 'ൡ'], |
| 70 | +['എe', '', 'ഈ'], |
| 71 | +['ഒo', '', 'ഊ'], |
| 72 | +['ാa', '', 'ാാ'], |
| 73 | +['ീi', '', 'ീീ'], |
| 74 | +['ൂu', '', 'ൂൂ'], |
| 75 | +['ൂo', '', 'ൂൂ'], |
| 76 | +['ൄR', '', 'ൄൄ'], |
| 77 | +['േE', '', 'േേ'], |
| 78 | +['ോO', '', 'ോോ'], |
| 79 | +['ൗu', '', 'ൗൗ'], |
| 80 | +['\u0d62\\^', '', '\u0d63'], |
| 81 | +['\u0d63\\^', '', '\u0d63\u0d63'], |
| 82 | +['ക്h', '', 'ഖ്'], |
| 83 | +['ഗ്h', '', 'ഘ്'], |
| 84 | +['ൻg', '', 'ങ്'], |
| 85 | +['ച്h', '', 'ഛ്'], |
| 86 | +['ജ്h', '', 'ഝ്'], |
| 87 | +['ട്h', '', 'ഠ്'], |
| 88 | +['ഡ്h', '', 'ഢ്'], |
| 89 | +['ത്h', '', 'ഥ്'], |
| 90 | +['ദ്h', '', 'ധ്'], |
| 91 | +['പ്h', '', 'ഫ്'], |
| 92 | +['ബ്h', '', 'ഭ്'], |
| 93 | +['ംa', '', 'മ'], |
| 94 | +['ംA', '', 'മാ'], |
| 95 | +['ംi', '', 'മി'], |
| 96 | +['ംI', '', 'മീ'], |
| 97 | +['ംu', '', 'മു'], |
| 98 | +['ംU', '', 'മൂ'], |
| 99 | +['ംR', '', 'മൃ'], |
| 100 | +['ംe', '', 'മെ'], |
| 101 | +['ംE', '', 'മേ'], |
| 102 | +['ംo', '', 'മൊ'], |
| 103 | +['ംO', '', 'മോ'], |
| 104 | +['ംm', '', 'മ്മ്'], |
| 105 | +['([^സ])ംr', '', '$1മ്ര്'], |
| 106 | +['ംp', '', 'മ്പ്'], |
| 107 | +['([^സ])ം(l|L)', '', '$1മ്ല്'], |
| 108 | +['ം~', '', 'മ്'], |
| 109 | +['([^സ])ംn', '', '$1മ്ന്'], |
| 110 | +['([^സ])ംy', '', '$1മ്യ്'], |
| 111 | +['സ്h', '', 'ഷ്'], |
| 112 | +['ശ്h', '', 'ഴ്'], |
| 113 | +['ൺ\\\\\\\\', '', 'ണ്\u200d'], // old style chillu N |
| 114 | +['ൺ~', '', 'ണ്'], |
| 115 | +['ൺR', '', 'ണൃ'], |
| 116 | +['ൺN', '', 'ണ്ണ്'], |
| 117 | +['ൺT', '', 'ണ്ട്'], |
| 118 | +['ൺD', '', 'ണ്ഡ്'], |
| 119 | +['ൺy', '', 'ണ്യ്'], |
| 120 | +['ൺv', '', 'ണ്വ്'], |
| 121 | +['ൺm', '', 'ണ്മ്'], |
| 122 | +['ൻ\\\\\\\\', '', 'ന്\u200d'], // old style chillu n |
| 123 | +['ൻ~', '', 'ന്'], |
| 124 | +['ൻr', '', 'ന്ര്'], |
| 125 | +['ൻR', '', 'നൃ'], |
| 126 | +['ൻk', '', 'ങ്ക്'], |
| 127 | +['ൻj', '', 'ഞ്'], |
| 128 | +['ൻn', '', 'ന്ന്'], |
| 129 | +['ൻd', '', 'ന്ദ്'], |
| 130 | +['ൻt', '', 'ന്റ്'], |
| 131 | +['ൻm', '', 'ന്മ്'], |
| 132 | +['ൻL', '', 'ന്ല്'], |
| 133 | +['ൻv', '', 'ന്വ്'], |
| 134 | +['ൻy', '', 'ന്യ്'], |
| 135 | +['ർ\\\\\\\\', '', 'ര്\u200d'], // old style chill r |
| 136 | +['ർ~', '', 'ര്'], |
| 137 | +['ർr', '', 'റ്'], |
| 138 | +['ർR', '', 'രൃ'], |
| 139 | +['ർy', '', 'ര്യ്'], |
| 140 | +['ൽ\\\\\\\\', '', 'ല്\u200d'], // old style chillu l |
| 141 | +['ൽ~', '', 'ല്'], |
| 142 | +['ൽR', '', 'ലൃ'], |
| 143 | +['ൽ(l|L)', '', 'ല്ല്'], |
| 144 | +['ൽp', '', 'ല്പ്'], |
| 145 | +['ൽy', '', 'ല്യ്'], |
| 146 | +['ൽv', '', 'ല്വ്'], |
| 147 | +['ൾ\\\\\\\\', '', 'ള്\u200d'], // old style chillu L |
| 148 | +['ൾ~', '', 'ള്'], |
| 149 | +['ൾR', '', 'ളൃ'], |
| 150 | +['ൾL', '', 'ള്ള്'], |
| 151 | +['ൾy', '', 'ള്യ്'], |
| 152 | +['ൾl', '', 'ഌ'], |
| 153 | +['ൿ\\\\\\\\', '', 'ക്\u200d'], // old style chillu k |
| 154 | +['ൿR', '', 'കൃ'], |
| 155 | +['ൿy', '', 'ക്യ്'], |
| 156 | +['ൿ(l|L)', '', 'ക്ല്'], |
| 157 | +['ൿv', '', 'ക്വ്'], |
| 158 | +['ൿ(k|c)', '', 'ക്ക്'], |
| 159 | +['([ക-ഹ])a', '', '$1ാ'], |
| 160 | +['([ക-ഹ])്a', '', '$1'], |
| 161 | +['ൺa', '', 'ണ'], |
| 162 | +['ൻa', '', 'ന'], |
| 163 | +['ർa', '', 'ര'], |
| 164 | +['ൽa', '', 'ല'], |
| 165 | +['ൾa', '', 'ള'], |
| 166 | +['ൿa', '', 'ക'], |
| 167 | +['([ക-ഹ])്A', '', '$1ാ'], |
| 168 | +['ൺA', '', 'ണാ'], |
| 169 | +['ൻA', '', 'നാ'], |
| 170 | +['ർA', '', 'രാ'], |
| 171 | +['ൽA', '', 'ലാ'], |
| 172 | +['ൾA', '', 'ളാ'], |
| 173 | +['ൿA', '', 'കാ'], |
| 174 | +['([ക-ഹ])്i', '', '$1ി'], |
| 175 | +['ൺi', '', 'ണി'], |
| 176 | +['ൻi', '', 'നി'], |
| 177 | +['ർi', '', 'രി'], |
| 178 | +['ൽi', '', 'ലി'], |
| 179 | +['ൾi', '', 'ളി'], |
| 180 | +['ൿi', '', 'കി'], |
| 181 | +['([ക-ഹ])്I', '', '$1ീ'], |
| 182 | +['ൺI', '', 'ണീ'], |
| 183 | +['ൻI', '', 'നീ'], |
| 184 | +['ർI', '', 'രീ'], |
| 185 | +['ൽI', '', 'ലീ'], |
| 186 | +['ൾI', '', 'ളീ'], |
| 187 | +['ൿI', '', 'കീ'], |
| 188 | +['([ക-ഹ])ിi', '', '$1ീ'], |
| 189 | +['([ക-ഹ])െe', '', '$1ീ'], |
| 190 | +['([ക-ഹ])്u', '', '$1ു'], |
| 191 | +['ൺu', '', 'ണു'], |
| 192 | +['ൻu', '', 'നു'], |
| 193 | +['ർu', '', 'രു'], |
| 194 | +['ൽu', '', 'ലു'], |
| 195 | +['ൾu', '', 'ളു'], |
| 196 | +['ൿu', '', 'കു'], |
| 197 | +['([ക-ഹ])്U', '', '$1ൂ'], |
| 198 | +['([ക-ഹ])ുu', '', '$1ൂ'], |
| 199 | +['ൺU', '', 'ണൂ'], |
| 200 | +['ൻU', '', 'നൂ'], |
| 201 | +['ർU', '', 'രൂ'], |
| 202 | +['ൽU', '', 'ലൂ'], |
| 203 | +['ൾU', '', 'ളൂ'], |
| 204 | +['ൿU', '', 'കൂ'], |
| 205 | +['([ക-ഹ])ൊo', '', '$1ൂ'], |
| 206 | +['([ക-ഹ])ൃR', '', '$1ൄ'], |
| 207 | +['([ക-ഹ])്e', '', '$1െ'], |
| 208 | +['ൺe', '', 'ണെ'], |
| 209 | +['ൻe', '', 'നെ'], |
| 210 | +['ർe', '', 'രെ'], |
| 211 | +['ൽe', '', 'ലെ'], |
| 212 | +['ൾe', '', 'ളെ'], |
| 213 | +['ൿe', '', 'കെ'], |
| 214 | +['([ക-ഹ])്E', '', '$1േ'], |
| 215 | +['ൺE', '', 'ണേ'], |
| 216 | +['ൻE', '', 'നേ'], |
| 217 | +['ർE', '', 'രേ'], |
| 218 | +['ൽE', '', 'ലേ'], |
| 219 | +['ൾE', '', 'ളേ'], |
| 220 | +['ൿE', '', 'കേ'], |
| 221 | +['([ക-ഹ])i', '', '$1ൈ'], |
| 222 | +['([ക-ഹ])്o', '', '$1ൊ'], |
| 223 | +['ൺo', '', 'ണൊ'], |
| 224 | +['ൻo', '', 'നൊ'], |
| 225 | +['ർo', '', 'രൊ'], |
| 226 | +['ൽo', '', 'ലൊ'], |
| 227 | +['ൾo', '', 'ളൊ'], |
| 228 | +['ൿo', '', 'കൊ'], |
| 229 | +['([ക-ഹ])്O', '', '$1ോ'], |
| 230 | +['ൺO', '', 'ണോ'], |
| 231 | +['ൻO', '', 'നോ'], |
| 232 | +['ർO', '', 'രോ'], |
| 233 | +['ൽO', '', 'ലോ'], |
| 234 | +['ൾO', '', 'ളോ'], |
| 235 | +['ൿO', '', 'കോ'], |
| 236 | +['([ക-ഹ])u', '', '$1ൗ'], |
| 237 | +['([ക-ഹ])U', '', '$1ൌ'], |
| 238 | +['([അ-്])m', '', '$1ം'], |
| 239 | +['\\\\0', '', '൦'], // escape to ml digit 0 by \0 |
| 240 | +['\\\\1', '', '൧'], // escape to ml digit 1 by \1 |
| 241 | +['\\\\2', '', '൨'], // escape to ml digit 2 by \2 |
| 242 | +['\\\\3', '', '൩'], // escape to ml digit 3 by \3 |
| 243 | +['\\\\4', '', '൪'], // escape to ml digit 4 by \4 |
| 244 | +['\\\\5', '', '൫'], // escape to ml digit 5 by \5 |
| 245 | +['\\\\6', '', '൬'], // escape to ml digit 6 by \6 |
| 246 | +['\\\\7', '', '൭'], // escape to ml digit 7 by \7 |
| 247 | +['\\\\8', '', '൮'], // escape to ml digit 8 by \8 |
| 248 | +['\\\\9', '', '൯'], // escape to ml digit 9 by \9 |
| 249 | +['മ്\\\\', '', 'ം'], |
| 250 | +['ആ\\\\', '', 'ാ'], |
| 251 | +['ഇ\\\\', '', 'ി'], |
| 252 | +['ഈ\\\\', '', 'ീ'], |
| 253 | +['ഉ\\\\', '', 'ു'], |
| 254 | +['ഊ\\\\', '', 'ൂ'], |
| 255 | +['ഋ\\\\', '', 'ൃ'], |
| 256 | +['ൠ\\\\', '', 'ൄ'], |
| 257 | +['എ\\\\', '', 'െ'], |
| 258 | +['ഏ\\\\', '', 'േ'], |
| 259 | +['ഐ\\\\', '', 'ൈ'], |
| 260 | +['ഒ\\\\', '', 'ൊ'], |
| 261 | +['ഓ\\\\', '', 'ോ'], |
| 262 | +['ഔ\\\\', '', 'ൗ'], |
| 263 | +['ൗ\\\\', '', 'ൌ'], |
| 264 | +['ഌ\\\\', '', 'ൢ'], |
| 265 | +['ൡ\\\\', '', 'ൣ'], |
| 266 | +['(([ൺ-ൿം])\u200c+)?A', '', '$2ആ'], |
| 267 | +['(([ൺ-ൿം])\u200c+)?B', '', '$2ബ്ബ്'], |
| 268 | +['(([ൺ-ൿം])\u200c+)?C', '', '$2ച്ച്'], |
| 269 | +['(([ൺ-ൿം])\u200c+)?D', '', '$2ഡ്'], |
| 270 | +['(([ൺ-ൿം])\u200c+)?E', '', '$2ഏ'], |
| 271 | +['(([ൺ-ൿം])\u200c+)?F', '', '$2ഫ്'], |
| 272 | +['(([ൺ-ൿം])\u200c+)?G', '', '$2ഗ്ഗ്'], |
| 273 | +['(([ൺ-ൿം])\u200c+)?H', '', '$2ഃ'], |
| 274 | +['(([ൺ-ൿം])\u200c+)?I', '', '$2ഐ'], |
| 275 | +['(([ൺ-ൿം])\u200c+)?J', '', '$2ജ്ജ്'], |
| 276 | +['(([ൺ-ൿം])\u200c+)?K', '', '$2ക്ക്'], |
| 277 | +['(([ൺ-ൿം])\u200c+)?L', '', '$2ൾ'], |
| 278 | +['(([ൺ-ൿം])\u200c+)?M', '', '$2മ്മ്'], |
| 279 | +['(([ൺ-ൿം])\u200c+)?N', '', '$2ൺ'], |
| 280 | +['(([ൺ-ൿം])\u200c+)?O', '', '$2ഓ'], |
| 281 | +['(([ൺ-ൿം])\u200c+)?P', '', '$2പ്പ്'], |
| 282 | +['(([ൺ-ൿം])\u200c+)?Q', '', '$2ക്യ്'], |
| 283 | +['(([ൺ-ൿം])\u200c+)?R', '', '$2ഋ'], |
| 284 | +['(([ൺ-ൿം])\u200c+)?(S|z)', '', '$2ശ്'], |
| 285 | +['(([ൺ-ൿം])\u200c+)?T', '', '$2ട്'], |
| 286 | +['(([ൺ-ൿം])\u200c+)?U', '', '$2ഊ'], |
| 287 | +['(([ൺ-ൿം])\u200c+)?(V|W)', '', '$2വ്വ്'], |
| 288 | +['(([ൺ-ൿം])\u200c+)?X', '', '$2ക്ഷ്'], |
| 289 | +['(([ൺ-ൿം])\u200c+)?Y', '', '$2യ്യ്'], |
| 290 | +['(([ൺ-ൿം])\u200c+)?Z', '', '$2ശ്ശ്'], |
| 291 | +['(([ൺ-ൿം])\u200c+)?a', '', '$2അ'], |
| 292 | +['(([ൺ-ൿം])\u200c+)?b', '', '$2ബ്'], |
| 293 | +['(([ൺ-ൿം])\u200c+)?c', '', '$2ൿ'], |
| 294 | +['(([ൺ-ൿം])\u200c+)?d', '', '$2ദ്'], |
| 295 | +['(([ൺ-ൿം])\u200c+)?e', '', '$2എ'], |
| 296 | +['(([ൺ-ൿം])\u200c+)?f', '', '$2ഫ്'], |
| 297 | +['(([ൺ-ൿം])\u200c+)?g', '', '$2ഗ്'], |
| 298 | +['(([ൺ-ൿം])\u200c+)?h', '', '$2ഹ്'], |
| 299 | +['(([ൺ-ൿം])\u200c+)?i', '', '$2ഇ'], |
| 300 | +['(([ൺ-ൿം])\u200c+)?j', '', '$2ജ്'], |
| 301 | +['(([ൺ-ൿം])\u200c+)?k', '', '$2ക്'], |
| 302 | +['(([ൺ-ൿം])\u200c+)?l', '', '$2ൽ'], |
| 303 | +['(([ൺ-ൿം])\u200c+)?m', '', '$2മ്'], |
| 304 | +['(([ൺ-ൿം])\u200c+)?n', '', '$2ൻ'], |
| 305 | +['(([ൺ-ൿം])\u200c+)?o', '', '$2ഒ'], |
| 306 | +['(([ൺ-ൿം])\u200c+)?p', '', '$2പ്'], |
| 307 | +['(([ൺ-ൿം])\u200c+)?q', '', '$2ക്ക്'], |
| 308 | +['(([ൺ-ൿം])\u200c+)?r', '', '$2ർ'], |
| 309 | +['(([ൺ-ൿം])\u200c+)?s', '', '$2സ്'], |
| 310 | +['(([ൺ-ൿം])\u200c+)?t', '', '$2റ്റ്'], // tta according to 5.1 |
| 311 | +['(([ൺ-ൿം])\u200c+)?u', '', '$2ഉ'], |
| 312 | +['(([ൺ-ൿം])\u200c+)?(v|w)', '', '$2വ്'], |
| 313 | +['(([ൺ-ൿം])\u200c+)?x', '', '$2ക്ഷ്'], |
| 314 | +['(([ൺ-ൿം])\u200c+)?y', '', '$2യ്'], |
| 315 | +['(([ൺ-ൿം])\u200c+)?~', '', '$2്'], |
| 316 | +['(\u200C)*_', '', '\u200c'], |
| 317 | +['//', '', 'ऽ'], |
| 318 | +['1/4\\\\', '', '൳'], |
| 319 | +['1/2\\\\', '', '൴'], |
| 320 | +['3/4\\\\', '', '൵'], |
| 321 | +['10\\\\', '', '\u0D70'], |
| 322 | +['100\\\\', '', '\u0D71'], |
| 323 | +['1000\\\\', '', '\u0D72'], |
| 324 | +['\\-\\-\\-\\\\', '', '—'], // em dash |
| 325 | +['\\-\\-\\\\', '', '–'], // en dash |
| 326 | +['\\\\\\-', '', '−'], |
| 327 | +['\\\\\\*', '', '×'], |
| 328 | +['\\\\/', '', '÷'] |
| 329 | +]; |
| 330 | + |
| 331 | +jQuery.narayam.addScheme( 'ml', { |
| 332 | + 'namemsg': 'narayam-ml', |
| 333 | + 'extended_keyboard': false, |
| 334 | + 'lookbackLength': 2, |
| 335 | + 'rules': rules |
| 336 | +} ); |
Property changes on: trunk/extensions/Narayam/ext.narayam.rules.ml.js |
___________________________________________________________________ |
Added: svn:eol-style |
1 | 337 | + native |
Index: trunk/extensions/Narayam/Narayam.php |
— | — | @@ -96,7 +96,7 @@ |
97 | 97 | 'dependencies' => 'ext.narayam.core', |
98 | 98 | ); |
99 | 99 | $wgResourceModules['ext.narayam.core'] = $narayamTpl + array( |
100 | | - 'scripts' => 'Narayam.js', // TODO: Rename files |
| 100 | + 'scripts' => 'ext.narayam.core.js', |
101 | 101 | 'styles' => 'ext.narayam.core.css', |
102 | 102 | 'skinStyles' => array( |
103 | 103 | 'monobook' => 'ext.narayam.core-monobook.css', |
— | — | @@ -110,42 +110,42 @@ |
111 | 111 | 'dependencies' => array( 'mediawiki.util', 'jquery.textSelection' ), |
112 | 112 | ); |
113 | 113 | $wgResourceModules['ext.narayam.rules.bn-avro'] = $narayamTpl + array( |
114 | | - 'scripts' => 'bn_avro_rules.js', |
| 114 | + 'scripts' => 'ext.narayam.rules.bn-avro.js', |
115 | 115 | 'messages' => array( 'narayam-bn-avro' ), |
116 | 116 | 'dependencies' => 'ext.narayam.core', |
117 | 117 | ); |
118 | 118 | $wgResourceModules['ext.narayam.rules.bn-inscript'] = $narayamTpl + array( |
119 | | - 'scripts' => 'bn_inscript_rules.js', |
| 119 | + 'scripts' => 'ext.narayam.rules.bn-inscript.js', |
120 | 120 | 'messages' => array( 'narayam-bn-inscript' ), |
121 | 121 | 'dependencies' => 'ext.narayam.core', |
122 | 122 | ); |
123 | 123 | $wgResourceModules['ext.narayam.rules.bn-nkb'] = $narayamTpl + array( |
124 | | - 'scripts' => 'bn_nkb_rules.js', |
| 124 | + 'scripts' => 'ext.narayam.rules.bn-nkb.js', |
125 | 125 | 'messages' => array( 'narayam-bn-nkb' ), |
126 | 126 | 'dependencies' => 'ext.narayam.core', |
127 | 127 | ); |
128 | 128 | $wgResourceModules['ext.narayam.rules.ml-inscript'] = $narayamTpl + array( |
129 | | - 'scripts' => 'ml_inscript_rules.js', |
| 129 | + 'scripts' => 'ext.narayam.rules.ml-inscript.js', |
130 | 130 | 'messages' => array( 'narayam-ml-inscript' ), |
131 | 131 | 'dependencies' => 'ext.narayam.core', |
132 | 132 | ); |
133 | 133 | $wgResourceModules['ext.narayam.rules.ml'] = $narayamTpl + array( |
134 | | - 'scripts' => 'ml_rules.js', |
| 134 | + 'scripts' => 'ext.narayam.rules.ml.js', |
135 | 135 | 'messages' => array( 'narayam-ml' ), |
136 | 136 | 'dependencies' => 'ext.narayam.core', |
137 | 137 | ); |
138 | 138 | $wgResourceModules['ext.narayam.rules.sa'] = $narayamTpl + array( |
139 | | - 'scripts' => 'sa_rules.js', |
| 139 | + 'scripts' => 'ext.narayam.rules.sa.js', |
140 | 140 | 'messages' => array( 'narayam-sa' ), |
141 | 141 | 'dependencies' => 'ext.narayam.core', |
142 | 142 | ); |
143 | 143 | $wgResourceModules['ext.narayam.rules.ta99'] = $narayamTpl + array( |
144 | | - 'scripts' => 'ta99_rules.js', |
| 144 | + 'scripts' => 'ext.narayam.rules.ta99.js', |
145 | 145 | 'messages' => array( 'narayam-ta99' ), |
146 | 146 | 'dependencies' => 'ext.narayam.core', |
147 | 147 | ); |
148 | 148 | $wgResourceModules['ext.narayam.rules.ta'] = $narayamTpl + array( |
149 | | - 'scripts' => 'ta_rules.js', |
| 149 | + 'scripts' => 'ext.narayam.rules.ta.js', |
150 | 150 | 'messages' => array( 'narayam-ta' ), |
151 | 151 | 'dependencies' => 'ext.narayam.core', |
152 | 152 | ); |