Index: trunk/extensions/Narayam/ext.narayam.rules.hi-inscript.js |
— | — | @@ -0,0 +1,123 @@ |
| 2 | +/** |
| 3 | + * InScript regular expression rules table for Devanagari script for Hindi |
| 4 | + * According to CDAC's "Enhanced InScript Keyboard Layout 5.2" |
| 5 | + * @author Junaid P V ([[user:Junaidpv]]) |
| 6 | + * @date 2011-02-26 |
| 7 | + * License: GPLv3 |
| 8 | + */ |
| 9 | + |
| 10 | + // Normal rules |
| 11 | +var rules = [ |
| 12 | +['X', '', '\u0901'], |
| 13 | +['x', '', '\u0902'], |
| 14 | +['_', '', '\u0903'], |
| 15 | +['D', '', '\u0905'], |
| 16 | +['E', '', '\u0906'], |
| 17 | +['F', '', '\u0907'], |
| 18 | +['R', '', '\u0908'], |
| 19 | +['G', '', '\u0909'], |
| 20 | +['T', '', '\u090A'], |
| 21 | +['\\+', '', '\u090B'], |
| 22 | +['!', '', '\u090D'], |
| 23 | +['S', '', '\u090F'], |
| 24 | +['W', '', '\u0910'], |
| 25 | +['\\|', '', '\u0911'], |
| 26 | +['A', '', '\u0913'], |
| 27 | +['Q', '', '\u0914'], |
| 28 | +['k', '', '\u0915'], |
| 29 | +['K', '', '\u0916'], |
| 30 | +['i', '', '\u0917'], |
| 31 | +['I', '', '\u0918'], |
| 32 | +['U', '', '\u0919'], |
| 33 | +[';', '', '\u091A'], |
| 34 | +['\\:', '', '\u091B'], |
| 35 | +['p', '', '\u091C'], |
| 36 | +['P', '', '\u091D'], |
| 37 | +['\\}', '', '\u091E'], |
| 38 | +["'", '', '\u091F'], |
| 39 | +['"', '', '\u0920'], |
| 40 | +['\\[', '', '\u0921'], |
| 41 | +['\\{', '', '\u0922'], |
| 42 | +['C', '', '\u0923'], |
| 43 | +['l', '', '\u0924'], |
| 44 | +['L', '', '\u0925'], |
| 45 | +['o', '', '\u0926'], |
| 46 | +['O', '', '\u0927'], |
| 47 | +['v', '', '\u0928'], |
| 48 | +['h', '', '\u092A'], |
| 49 | +['H', '', '\u092B'], |
| 50 | +['y', '', '\u092C'], |
| 51 | +['Y', '', '\u092D'], |
| 52 | +['c', '', '\u092E'], |
| 53 | +['/', '', '\u092F'], |
| 54 | +['j', '', '\u0930'], |
| 55 | +['n', '', '\u0932'], |
| 56 | +['b', '', '\u0935'], |
| 57 | +['M', '', '\u0936'], |
| 58 | +['\\<', '', '\u0937'], |
| 59 | +['m', '', '\u0938'], |
| 60 | +['u', '', '\u0939'], |
| 61 | +['\\]', '', '\u093C'], |
| 62 | +['e', '', '\u093E'], |
| 63 | +['f', '', '\u093F'], |
| 64 | +['r', '', '\u0940'], |
| 65 | +['g', '', '\u0941'], |
| 66 | +['t', '', '\u0942'], |
| 67 | +['\\=', '', '\u0943'], |
| 68 | +['\\@', '', '\u0945'], |
| 69 | +['s', '', '\u0947'], |
| 70 | +['w', '', '\u0948'], |
| 71 | +['\\\\', '', '\u0949'], |
| 72 | +['a', '', '\u094B'], |
| 73 | +['q', '', '\u094C'], |
| 74 | +['d', '', '\u094D'], |
| 75 | +['\\>', '', '\u0964'], |
| 76 | +['0', '', '\u0966'], |
| 77 | +['1', '', '\u0967'], |
| 78 | +['2', '', '\u0968'], |
| 79 | +['3', '', '\u0969'], |
| 80 | +['4', '', '\u096A'], |
| 81 | +['5', '', '\u096B'], |
| 82 | +['6', '', '\u096C'], |
| 83 | +['7', '', '\u096D'], |
| 84 | +['8', '', '\u096E'], |
| 85 | +['9', '', '\u096F'], |
| 86 | +['\\#', '', '\u094D\u0930'], |
| 87 | +['\\$', '', '\u0930\u094D'], |
| 88 | +['\\%', '', '\u091C\u094D\u091E'], |
| 89 | +['\\^', '', '\u0924\u094D\u0930'], |
| 90 | +['\\&', '', '\u0915\u094D\u0937'], |
| 91 | +['\\*', '', '\u0936\u094D\u0930'], |
| 92 | +['\\(', '', '\u200D'], |
| 93 | +['\\)', '', '\u200C'] |
| 94 | +]; |
| 95 | + |
| 96 | +var rules_x = [ |
| 97 | +['F', '', '\u090C'], |
| 98 | +['N', '', '\u0933'], |
| 99 | +['\\>', '', '\u093D'], |
| 100 | +['\\=', '', '\u0944'], |
| 101 | +['X', '', '\u0950'], |
| 102 | +['e', '', '\u0951'], |
| 103 | +['d', '', '\u0952'], |
| 104 | +['k', '', '\u0958'], |
| 105 | +['K', '', '\u0959'], |
| 106 | +['i', '', '\u095A'], |
| 107 | +['p', '', '\u095B'], |
| 108 | +['\\[', '', '\u095C'], |
| 109 | +['\\+', '', '\u0960'], |
| 110 | +['R', '', '\u0961'], |
| 111 | +['f', '', '\u0962'], |
| 112 | +['r', '', '\u0963'], |
| 113 | +['\\.', '', '\u0965'], |
| 114 | +[',', '', '\u0970'], |
| 115 | +['\\$', '', '\u20B9'] |
| 116 | +]; |
| 117 | + |
| 118 | +jQuery.narayam.addScheme( 'hi-inscript', { |
| 119 | + 'namemsg': 'narayam-hi-inscript', |
| 120 | + 'extended_keyboard': true, |
| 121 | + 'lookbackLength': 0, |
| 122 | + 'rules': rules, |
| 123 | + 'rules_x': rules_x |
| 124 | +} ); |
\ No newline at end of file |
Property changes on: trunk/extensions/Narayam/ext.narayam.rules.hi-inscript.js |
___________________________________________________________________ |
Added: svn:eol-style |
1 | 125 | + native |
Index: trunk/extensions/Narayam/Narayam.i18n.php |
— | — | @@ -18,6 +18,7 @@ |
19 | 19 | 'narayam-toggle-ime' => 'To toggle IM ($1)', // FIXME: better message |
20 | 20 | 'narayam-help-page' => 'Help:Typing', |
21 | 21 | 'narayam-checkbox-tooltip' => 'To toggle input method on and off', // FIXME: better message |
| 22 | + 'narayam-hi-inscript' => 'Hindi InScript', |
22 | 23 | 'narayam-ml' => 'Malayalam Transliteration', |
23 | 24 | 'narayam-ml-inscript' => 'Malayalam InScript', |
24 | 25 | 'narayam-sa' => 'Sanskrit Transliteration', |
Index: trunk/extensions/Narayam/Narayam.php |
— | — | @@ -50,6 +50,9 @@ |
51 | 51 | 'bn-inscript' => 'ext.narayam.rules.bn-inscript', |
52 | 52 | 'bn-nkb' => 'ext.narayam.rules.bn-nkb', |
53 | 53 | ), |
| 54 | + 'hi' => array( |
| 55 | + 'hi-inscript' => 'ext.narayam.rules.hi-inscript', |
| 56 | + ), |
54 | 57 | 'ml' => array( |
55 | 58 | 'ml' => 'ext.narayam.rules.ml', |
56 | 59 | 'ml-inscript' => 'ext.narayam.rules.ml-inscript', |
— | — | @@ -125,6 +128,11 @@ |
126 | 129 | 'messages' => array( 'narayam-bn-nkb' ), |
127 | 130 | 'dependencies' => 'ext.narayam.core', |
128 | 131 | ); |
| 132 | +$wgResourceModules['ext.narayam.rules.hi-inscript'] = $narayamTpl + array( |
| 133 | + 'scripts' => 'ext.narayam.rules.hi-inscript.js', |
| 134 | + 'messages' => array( 'narayam-hi-inscript' ), |
| 135 | + 'dependencies' => 'ext.narayam.core', |
| 136 | +); |
129 | 137 | $wgResourceModules['ext.narayam.rules.ml-inscript'] = $narayamTpl + array( |
130 | 138 | 'scripts' => 'ext.narayam.rules.ml-inscript.js', |
131 | 139 | 'messages' => array( 'narayam-ml-inscript' ), |