r103934 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r103933‎ | r103934 | r103935 >
Date:18:30, 22 November 2011
Author:amire80
Status:resolved (Comments)
Tags:
Comment:
Adding ru-standard.
Modified paths:
  • /trunk/extensions/Narayam/Narayam.i18n.php (modified) (history)
  • /trunk/extensions/Narayam/Narayam.php (modified) (history)
  • /trunk/extensions/Narayam/resources/ext.narayam.rules.ru-standard.js (added) (history)

Diff [purge]

Index: trunk/extensions/Narayam/resources/ext.narayam.rules.ru-standard.js
@@ -0,0 +1,98 @@
 2+/**
 3+ * Trasliteration rules table for standard Russian keyboard
 4+ * @author Amir (Алексей) Aharoni ([[User:Amire80]])
 5+ * @date 2011-11-21
 6+ * License: GPLv3, CC-BY-SA 3.0
 7+ */
 8+
 9+ // Normal rules
 10+var rules = [
 11+['Q', '', 'Й'],
 12+['W', '', 'Ц'],
 13+['E', '', 'У'],
 14+['R', '', 'К'],
 15+['T', '', 'Е'],
 16+['Y', '', 'Н'],
 17+['U', '', 'Г'],
 18+['I', '', 'Ш'],
 19+['O', '', 'Щ'],
 20+['P', '', 'З'],
 21+['{', '', 'Х'],
 22+['}', '', 'Ъ'],
 23+['A', '', 'Ф'],
 24+['S', '', 'Ы'],
 25+['D', '', 'В'],
 26+['F', '', 'А'],
 27+['G', '', 'П'],
 28+['H', '', 'Р'],
 29+['J', '', 'О'],
 30+['K', '', 'Л'],
 31+['L', '', 'Д'],
 32+[':', '', 'Ж'],
 33+['"', '', 'Э'],
 34+['Z', '', 'Я'],
 35+['X', '', 'Ч'],
 36+['C', '', 'С'],
 37+['V', '', 'М'],
 38+['B', '', 'И'],
 39+['N', '', 'Т'],
 40+['M', '', 'Ь'],
 41+['<', '', 'Б'],
 42+['>', '', 'Ю'],
 43+['?', '', ','],
 44+
 45+['q', '', 'й'],
 46+['w', '', 'ц'],
 47+['e', '', 'у'],
 48+['r', '', 'к'],
 49+['t', '', 'е'],
 50+['y', '', 'н'],
 51+['u', '', 'г'],
 52+['i', '', 'ш'],
 53+['o', '', 'щ'],
 54+['p', '', 'з'],
 55+['[', '', 'х'],
 56+[']', '', 'ъ'],
 57+['a', '', 'ф'],
 58+['s', '', 'ы'],
 59+['d', '', 'в'],
 60+['f', '', 'а'],
 61+['g', '', 'п'],
 62+['h', '', 'р'],
 63+['j', '', 'о'],
 64+['k', '', 'л'],
 65+['l', '', 'д'],
 66+[';', '', 'ж'],
 67+['\'', '', 'э'],
 68+['z', '', 'я'],
 69+['x', '', 'ч'],
 70+['c', '', 'с'],
 71+['v', '', 'м'],
 72+['b', '', 'и'],
 73+['n', '', 'т'],
 74+['m', '', 'ь'],
 75+[',', '', 'б'],
 76+['.', '', 'ю'],
 77+['/', '', '.'],
 78+
 79+['`', '', 'ё'],
 80+['~', '', 'Ё'],
 81+
 82+['!', '', '!'], // 1
 83+['@', '', '"'], // 2
 84+['#', '', '№'], // 3
 85+['$', '', ';'], // 4
 86+// '%' is the same // 5
 87+['^', '', ':'], // 6
 88+['&', '', '?'], // 7
 89+// '*', '(' and ')' are the same // 8, 9, 0
 90+];
 91+
 92+
 93+jQuery.narayam.addScheme( 'ru-standard', {
 94+ 'namemsg': 'narayam-ru-standard',
 95+ 'extended_keyboard': false,
 96+ 'lookbackLength': 4,
 97+ 'keyBufferLength': 2,
 98+ 'rules': rules
 99+} );
Index: trunk/extensions/Narayam/Narayam.i18n.php
@@ -60,6 +60,7 @@
6161 'narayam-de' => 'German',
6262 'narayam-gu' => 'Gujarati transliteration',
6363 'narayam-gu-inscript' => 'Gujarati InScript',
 64+ 'narayam-ru-standard' => 'Russian Standard',
6465 );
6566
6667 /** Message documentation (Message documentation)
Index: trunk/extensions/Narayam/Narayam.php
@@ -122,6 +122,9 @@
123123 'gu' => 'ext.narayam.rules.gu',
124124 'gu-inscript' => 'ext.narayam.rules.gu-inscript',
125125 ),
 126+ 'ru' => array(
 127+ 'ru-standard' => 'ext.narayam.rules.ru-standard',
 128+ ),
126129 );
127130
128131 /* Setup */
@@ -201,6 +204,7 @@
202205 'narayam-ur',
203206 'narayam-gu',
204207 'narayam-gu-inscript',
 208+ 'narayam-ru-standard',
205209 ),
206210 'dependencies' => array(
207211 'mediawiki.util',
@@ -355,4 +359,8 @@
356360 $wgResourceModules['ext.narayam.rules.gu-inscript'] = $narayamTpl + array(
357361 'scripts' => 'resources/ext.narayam.rules.gu-inscript.js',
358362 'dependencies' => 'ext.narayam.core',
359 -);
\ No newline at end of file
 363+);
 364+$wgResourceModules['ext.narayam.rules.ru-standard'] = $narayamTpl + array(
 365+ 'scripts' => 'resources/ext.narayam.rules.ru-standard.js',
 366+ 'dependencies' => 'ext.narayam.core',
 367+);

Follow-up revisions

RevisionCommit summaryAuthorDate
r104012Followup to r104008, just comments.amire8010:01, 23 November 2011

Comments

#Comment by Nikerabbit (talk | contribs)   07:59, 23 November 2011

Trasliteration. Forgot to update your wip? :)

Status & tagging log