http://www.mediawiki.org/wiki/Special:Code/MediaWiki/83209

Revision: 83209
Author:   junaidpv
Date:     2011-03-04 07:37:04 +0000 (Fri, 04 Mar 2011)
Log Message:
-----------
Narayam: Sinhala more enhancements, Add Oriya transliteration and InScript 
schemes

Modified Paths:
--------------
    trunk/extensions/Narayam/Narayam.i18n.php
    trunk/extensions/Narayam/Narayam.php
    trunk/extensions/Narayam/ext.narayam.rules.si-singlish.js

Added Paths:
-----------
    trunk/extensions/Narayam/ext.narayam.rules.or-inscript.js
    trunk/extensions/Narayam/ext.narayam.rules.or.js

Modified: trunk/extensions/Narayam/Narayam.i18n.php
===================================================================
--- trunk/extensions/Narayam/Narayam.i18n.php   2011-03-04 06:01:30 UTC (rev 
83208)
+++ trunk/extensions/Narayam/Narayam.i18n.php   2011-03-04 07:37:04 UTC (rev 
83209)
@@ -23,6 +23,8 @@
        'narayam-kn-inscript' => 'Kannada InScript',
        'narayam-ml' => 'Malayalam Transliteration',
        'narayam-ml-inscript' => 'Malayalam InScript',
+       'narayam-or' => 'Oriya Transliteration',
+       'narayam-or-inscript' =>  'Oriya InScript',
        'narayam-sa' => 'Sanskrit Transliteration',
        'narayam-sa-inscript' => 'Sanskrit InScript',
        'narayam-si-singlish' => 'Sinhala Singlish',

Modified: trunk/extensions/Narayam/Narayam.php
===================================================================
--- trunk/extensions/Narayam/Narayam.php        2011-03-04 06:01:30 UTC (rev 
83208)
+++ trunk/extensions/Narayam/Narayam.php        2011-03-04 07:37:04 UTC (rev 
83209)
@@ -61,6 +61,10 @@
                'ml' => 'ext.narayam.rules.ml',
                'ml-inscript' => 'ext.narayam.rules.ml-inscript',
        ),
+       'or' => array(
+               'or' => 'ext.narayam.rules.or',
+               'or-inscript' => 'ext.narayam.rules.or-inscript',
+       ),
        'sa' => array(
                'sa' => 'ext.narayam.rules.sa',
                'sa-inscript' => 'ext.narayam.rules.sa-inscript',
@@ -161,6 +165,16 @@
        'messages' => array( 'narayam-ml' ),
        'dependencies' => 'ext.narayam.core',
 );
+$wgResourceModules['ext.narayam.rules.or'] = $narayamTpl + array(
+       'scripts' => 'ext.narayam.rules.or.js',
+       'messages' => array( 'narayam-or' ),
+       'dependencies' => 'ext.narayam.core',
+);
+$wgResourceModules['ext.narayam.rules.or-inscript'] = $narayamTpl + array(
+       'scripts' => 'ext.narayam.rules.or-inscript.js',
+       'messages' => array( 'narayam-or-inscript' ),
+       'dependencies' => 'ext.narayam.core',
+);
 $wgResourceModules['ext.narayam.rules.sa'] = $narayamTpl + array(
        'scripts' => 'ext.narayam.rules.sa.js',
        'messages' => array( 'narayam-sa' ),

Added: trunk/extensions/Narayam/ext.narayam.rules.or-inscript.js
===================================================================
--- trunk/extensions/Narayam/ext.narayam.rules.or-inscript.js                   
        (rev 0)
+++ trunk/extensions/Narayam/ext.narayam.rules.or-inscript.js   2011-03-04 
07:37:04 UTC (rev 83209)
@@ -0,0 +1,109 @@
+/**
+ * InScript regular expression rules table for Oriya script
+ * According to CDAC's "Enhanced InScript Keyboard Layout 5.2"
+ * @author Junaid P V ([[user:Junaidpv]])
+ * @date 2011-02-28
+ * License: GPLv3
+ */
+ 
+var rules = [
+['X', '', '\u0B01'],
+['x', '', '\u0B02'],
+['_', '', '\u0B03'],
+['D', '', '\u0B05'],
+['E', '', '\u0B06'],
+['F', '', '\u0B07'],
+['R', '', '\u0B08'],
+['G', '', '\u0B09'],
+['T', '', '\u0B0A'],
+['\\+', '', '\u0B0B'],
+['S', '', '\u0B0F'],
+['W', '', '\u0B10'],
+['A', '', '\u0B13'],
+['Q', '', '\u0B14'],
+['k', '', '\u0B15'],
+['K', '', '\u0B16'],
+['i', '', '\u0B17'],
+['I', '', '\u0B18'],
+['U', '', '\u0B19'],
+[';', '', '\u0B1A'],
+['\\:', '', '\u0B1B'],
+['p', '', '\u0B1C'],
+['P', '', '\u0B1D'],
+['\\}', '', '\u0B1E'],
+['`', '', '\u0B1F'],
+['~', '', '\u0B20'],
+['\\[', '', '\u0B21'],
+['\\{', '', '\u0B22'],
+['C', '', '\u0B23'],
+['l', '', '\u0B24'],
+['L', '', '\u0B25'],
+['o', '', '\u0B26'],
+['O', '', '\u0B27'],
+['v', '', '\u0B28'],
+['h', '', '\u0B2A'],
+['H', '', '\u0B2B'],
+['y', '', '\u0B2C'],
+['Y', '', '\u0B2D'],
+['c', '', '\u0B2E'],
+['\\?', '', '\u0B2F'],
+['j', '', '\u0B30'],
+['n', '', '\u0B32'],
+['N', '', '\u0B33'],
+['M', '', '\u0B36'],
+['\\<', '', '\u0B37'],
+['m', '', '\u0B38'],
+['u', '', '\u0B39'],
+['\\]', '', '\u0B3C'],
+['e', '', '\u0B3E'],
+['f', '', '\u0B3F'],
+['r', '', '\u0B40'],
+['g', '', '\u0B41'],
+['t', '', '\u0B42'],
+['\\=', '', '\u0B43'],
+['s', '', '\u0B47'],
+['w', '', '\u0B48'],
+['a', '', '\u0B4B'],
+['q', '', '\u0B4C'],
+['d', '', '\u0B4D'],
+['/', '', '\u0B5F'],
+['\\>', '', '\u0B64'],
+['0', '', '\u0B66'],
+['1', '', '\u0B67'],
+['2', '', '\u0B68'],
+['3', '', '\u0B69'],
+['4', '', '\u0B6A'],
+['5', '', '\u0B6B'],
+['6', '', '\u0B6C'],
+['7', '', '\u0B6D'],
+['8', '', '\u0B6E'],
+['9', '', '\u0B6F'],
+['b', '', '\u0B71'],
+['\\(', '', '\u200D'],
+['\\)', '', '\u200C']
+];
+
+var rules_x = [
+['F', '', '\u0B0C'],
+['b', '', '\u0B35'],
+['\\>', '', '\u0B3D'],
+['\\=', '', '\u0B44'],
+['\\[', '', '\u0B5C'],
+['\\{', '', '\u0B5D'],
+['\\+', '', '\u0B60'],
+['R', '', '\u0B61'],
+['f', '', '\u0B62'],
+['r', '', '\u0B63'],
+['\\.', '', '\u0B65'],
+['x', '', '\u0B70'],
+['\\$', '', '\u20B9']
+];
+
+jQuery.narayam.addScheme( 'or-inscript', {
+       'namemsg': 'narayam-or-inscript',
+       'extended_keyboard': true,
+       'lookbackLength': 0,
+       'keyBufferLength': 0,
+       'rules': rules,
+       'rules_x': rules_x
+} );


Property changes on: trunk/extensions/Narayam/ext.narayam.rules.or-inscript.js
___________________________________________________________________
Added: svn:eol-style
   + native

Added: trunk/extensions/Narayam/ext.narayam.rules.or.js
===================================================================
--- trunk/extensions/Narayam/ext.narayam.rules.or.js                            
(rev 0)
+++ trunk/extensions/Narayam/ext.narayam.rules.or.js    2011-03-04 07:37:04 UTC 
(rev 83209)
@@ -0,0 +1,125 @@
+/**
+ * Trasliteration regular expression rules table for Oriya
+ * @author Junaid P V ([[user:Junaidpv]])
+ * @date 2010-11-13
+ * @credit With help from Subhashish Panigrahi
+ * License: GPLv3, CC-BY-SA 3.0
+ */
+// Normal rules
+var rules = [
+['\\\\([A-Za-z\\>_~\\.0-9])', '\\\\','$2'],
+
+['ଞ୍ଜ୍h', '', 'ଞ୍ଝ୍'], // njh
+['ଙ୍ଗ୍h', '', 'ଙ୍ଘ୍'], // ngh
+
+['([କ-ହ])୍a', '','$2'],
+['([କ-ହ])(a|୍A)', '','$2ା'],
+['([କ-ହ])୍i', '','$2\u0b3f'],
+['([କ-ହ])(୍I|\u0b3fe)', '','$2ୀ'],
+['([କ-ହ])୍u', '','$2\u0b41'],
+['([କ-ହ])(୍U|\u0b41u)', '','$2\u0b42'],
+['([କ-ହ])୍R', '','$2\u0b43'],
+['([କ-ହ])\u0b43R', '','$2\u0b44'],
+['([କ-ହ])୍ଳ୍l', '','$2ୢ'],
+['([କ-ହ])ୢl', '','$2ୣ'],
+['([କ-ହ])୍e', '','$2େ'],
+['([କ-ହ])i', '','$2ୈ'],
+['([କ-ହ])୍o', '','$2ୋ'],
+['([କ-ହ])ୋu', '','$2ୌ'],
+['([କ-ହ])୍E', '','$2\u0B48'],
+
+['ଅa', '','ଆ'],
+['(ଅi|ଏe)', '','ଐ'],
+['(ଅu|ଓo|ଓO)', '','ଔ'],
+['ଋR', '','ୠ'],
+['ଳ୍l', '','ଌ'],
+['ଌl', '','ୡ'],
+
+['କ୍h', '','ଖ୍'],
+['ଗ୍h', '','ଘ୍'],
+['ନ୍g', '', 'ଙ୍ଗ୍'],   // ng
+['ଚ୍h', '','ଛ୍'],
+['ଜ୍h', '','ଝ୍'],
+['ନ୍j', '', 'ଞ୍ଜ୍'],   // nj
+['ଟ୍h', '','ଠ୍'],
+['ଡ୍h', '','ଢ୍'],
+['ତ୍h', '','ଥ୍'],
+['ଦ୍h', '','ଧ୍'],
+['ପ୍h', '','ଫ୍'],
+['ବ୍h', '','ଭ୍'],
+['ସ୍h', '','ଷ୍'],
+['।Z', '', '॥'],
+
+['a', '','ଅ'],
+['b', '','ବ୍'],
+['c','','ଚ୍'],
+['d', '','ଦ୍'],
+['e', '','ଏ'],
+['f', '','ଫ୍'],
+['g', '','ଗ୍'],
+['h', '','ହ୍'],
+['i', '','ଇ'],
+['j', '','ଜ୍'],
+['k', '','କ୍'],
+['l', '','ଲ୍'],
+['m', '','ମ୍'],
+['n', '','ନ୍'],
+['o', '','ଓ'],
+['p', '','ପ୍'],
+['q', '', 'କ୍ଷ୍'],
+['r', '','ର୍'],
+['s', '','ସ୍'],
+['t', '','ତ୍'],
+['u', '','ଉ'],
+['v', '', 'ୱ୍'],
+['w', '','ଵ୍'],
+['x', '','ଂ'],
+['y', '','ୟ୍'],
+['z', '','\u0B3C'],
+['A', '','ଆ'],
+['B', '','ବ୍'],
+['C', '','ଛ୍'],
+['D', '','ଡ୍'],
+['E', '','ଐ'],
+['F', '','ଫ୍'],
+['G', '','ଗ୍'],
+['H', '','ଃ'],
+['I', '','ଈ'],
+['J', '','ଝ୍'],
+['K', '','କ୍'],
+['L', '','ଳ୍'],
+['M', '','ମ୍'],
+['N', '','ଣ୍'],
+['O', '', 'ଔ'],
+['P', '','ଫ୍'],
+['Q', '', 'ଜ୍ଞ୍'],
+['R', '','ଋ'],
+['S', '','ଶ୍'],
+['T', '','ଟ୍'],
+['U', '','ଊ'],
+['V', '', 'ଵ୍'],
+['W', '','ଵ୍ଵ୍'],
+['X', '', 'ଁ'],
+['Y', '','ଯ୍'],
+['Z', '', '।'],
+['\\~', '','୍'],
+['//', '','ଽ'],
+['0', '','୦'],
+['1', '','୧'],
+['2', '','୨'],
+['3', '','୩'],
+['4', '','୪'],
+['5', '','୫'],
+['6', '','୬'],
+['7', '','୭'],
+['8', '','୮'],
+['9', '','୯']
+];
+
+jQuery.narayam.addScheme( 'or', {
+       'namemsg': 'narayam-or',
+       'extended_keyboard': true,
+       'lookbackLength': 0,
+       'keyBufferLength': 0,
+       'rules': rules
+} );


Property changes on: trunk/extensions/Narayam/ext.narayam.rules.or.js
___________________________________________________________________
Added: svn:eol-style
   + native

Modified: trunk/extensions/Narayam/ext.narayam.rules.si-singlish.js
===================================================================
--- trunk/extensions/Narayam/ext.narayam.rules.si-singlish.js   2011-03-04 
06:01:30 UTC (rev 83208)
+++ trunk/extensions/Narayam/ext.narayam.rules.si-singlish.js   2011-03-04 
07:37:04 UTC (rev 83209)
@@ -6,21 +6,29 @@
  * License: GPLv3
  */
  
- // Normal rules
+// Normal rules
 var rules = [
+['ඬ්හ්a', '', 'ඳ'],    // nndha
+['න්න්d', '', 'ඬ්'],   // nnd
+['න්න්g', '', 'ඟ්'],   // nng
+['ශ්‍රිi', '', 'ශ්‍රී'],       // shrii
+['ශ්‍රi', '', 'ශ්‍රි'],        // shri
+['ශ්r', '', 'ශ්‍ර'],   // shr
+
 ['([\\u0D9A-\\u0DC6])්a', '', '$1'],    // <consonant>a
 ['([\\u0D9A-\\u0DC6])a', '', '$1ා'],    // <consonant>aa
 ['([\\u0D9A-\\u0DC6])්A', '', '$1ැ'],    // <consonant>A
 ['([\\u0D9A-\\u0DC6])ැa', '', '$1ෑ'],    // <consonant>Aa
 ['([\\u0D9A-\\u0DC6])්i', '', '$1ි'],    // <consonant>i
-['([\\u0D9A-\\u0DC6])ිe', '', '$1ී'],    // <consonant>ie
+['([\\u0D9A-\\u0DC6])ි[ei]', '', '$1ී'],    // <consonant>ie
 ['([\\u0D9A-\\u0DC6])්u', '', '$1ු'],    // <consonant>u
 ['([\\u0D9A-\\u0DC6])ුu', '', '$1ූ'],    // <consonant>u
 ['([\\u0D9A-\\u0DC6])්e', '', '$1ෙ'],    // <consonant>e
-['([\\u0D9A-\\u0DC6])ෙi', '', '$1ේ'],    // <consonant>ei
+['([\\u0D9A-\\u0DC6])ෙ[ai]', '', '$1ේ'],    // <consonant>ei
 ['([\\u0D9A-\\u0DC6])්o', '', '$1ො'],    // <consonant>o
 ['([\\u0D9A-\\u0DC6])ොe', '', '$1ෝ'],    // <consonant>oe
 ['([\\u0D9A-\\u0DC6])u', '', '$1ෞ'],    // <consonant>au
+['([\\u0D9A-\\u0DC6])්I', '', '$1ෛ'],    // <consonant>I
 
 ['ළුu', '', 'ළුු'], // Luu
 
@@ -78,7 +86,7 @@
 ['l', '', 'ල්'],
 ['D', '', 'ඪ්'],
 ['d', '', 'ඩ්'],
-['(w|V)', '', 'ව්'],
+['(w|v)', '', 'ව්'],
 ['s', '', 'ස්'],
 ['q', '', 'ඣ්'],
 ['h', '', 'හ්'],
@@ -91,7 +99,7 @@
 jQuery.narayam.addScheme( 'si-singlish', {
        'namemsg': 'narayam-si-singlish',
        'extended_keyboard': false,
-       'lookbackLength': 2,
+       'lookbackLength': 5,
        'keyBufferLength': 0,
        'rules': rules
 } ); 


_______________________________________________
MediaWiki-CVS mailing list
MediaWiki-CVS@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to