X-Git-Url: http://git.chise.org/gitweb/?p=m17n%2Fm17n-contrib.git;a=blobdiff_plain;f=im%2Fsi-phonetic-static.mim;h=f7d0f000af051647638a09eb21c2711069eb4abb;hp=152504aa33a33e18c9dfe3cb6fc560087ec799e6;hb=e33e2435e071cecad038f0e5be9955ef20de9ce2;hpb=6a698ef4b8fd3ddfbe1f27484c2a2cbd18c0f0d5 diff --git a/im/si-phonetic-static.mim b/im/si-phonetic-static.mim index 152504a..f7d0f00 100644 --- a/im/si-phonetic-static.mim +++ b/im/si-phonetic-static.mim @@ -1,7 +1,7 @@ ;; si-phonetic-static.mim -- Sinhala phonetic static keymap ;; m17n Keymap file for Sinhala (Sri Lanka) (2006-04-26) ;; Maintainer: Harshula Jayasuriya -;; Last Updated: 2007-06-14 +;; Last Updated: 2007-07-01 ;; This is a phonetic static mapping for a standard US-English keyboard ;; (qwerty) ;; http://www.nongnu.org/sinhala/doc/keymaps/sinhala-keyboard_3.html @@ -102,21 +102,60 @@ ("Y" "්‍ය") ; 0x0dca,0x200d,0x0dba - yansaya ((A-r) "ර්‍") ; 0x0dbb,0x0dca,0x200d - repaya - ;; Need the first backslash to escape the second. - ((A-\\) "්‍") ; 0x0dca,0x200d - join - conjunct letters cons 0DCA ZWJ cons - ((A-|) "‍්") ; 0x200d,0x0dca - touch - cons ZWJ 0DCA cons + ((A-,) "්‍") ; 0x0dca,0x200d - join - conjunct letters cons 0DCA ZWJ cons + ((A-/) "‍්") ; 0x200d,0x0dca - touch - cons ZWJ 0DCA cons ;; Shift-space and Alt-space ((S-\ ) " ") ; 0x00a0 - no-break space ((A-\ ) "‌") ; 0x200c - ZWNJ + ((BackSpace) + (cond + ;; rakaaranshaya and yansaya + ((| (= @-1 0x0DBA) (= @-1 0x0DBB)) + (delete @-1) + (delete-al-zwj) + ) + ;; touch + ((& (= @-2 0x200D) (= @-1 0x0DCA)) + (delete @-1) + (delete @-1) + ) + ;; join + ((= @-1 0x200D) + (delete-al-zwj) + ) + (1 + (delete @-1) + ) + ) + ) + ) ) +(macro + (delete-al-zwj (set x 0)) + + (delete-al-zwj + (cond + ((& (= @-2 0x0DCA) (= @-1 0x200D)) + (delete @-1) + (delete @-1) + ;; repaya + (cond + ((= @-1 0x0DBB) + (delete @-1) + ) + ) + ) + ) + ) + +) (state (init (phon) ) ) -