Index: trunk/extensions/Narayam/ext.narayam.rules.eo.js |
— | — | @@ -0,0 +1,26 @@ |
| 2 | +/** |
| 3 | + * Rule tables for Esperanto x-code transcription. |
| 4 | + * @author Brion Vibber ([[user:Brion VIBBER]]) |
| 5 | + * @date 2011-04-05 |
| 6 | + * License: GPLv3 |
| 7 | + */ |
| 8 | + |
| 9 | +(function() { |
| 10 | + |
| 11 | +var rules = []; |
| 12 | +var chars = {C: 'Ĉ', G: 'Ĝ', H: 'Ĥ', J: 'Ĵ', S: 'Ŝ', U: 'Ŭ', |
| 13 | + c: 'ĉ', g: 'ĝ', h: 'ĥ', j: 'ĵ', s: 'ŝ', u: 'ŭ'}; |
| 14 | +jQuery.each(chars, function(ascii, accented) { |
| 15 | + rules.push([ascii + '[Xx]', ascii, accented]); |
| 16 | + rules.push([accented + '([Xx])', '[Xx]', ascii + '$1']); |
| 17 | +}); |
| 18 | + |
| 19 | +jQuery.narayam.addScheme( 'eo', { |
| 20 | + 'namemsg': 'narayam-eo', |
| 21 | + 'extended_keyboard': false, |
| 22 | + 'lookbackLength': 1, |
| 23 | + 'keyBufferLength': 1, |
| 24 | + 'rules': rules |
| 25 | +} ); |
| 26 | + |
| 27 | +})(jQuery); |