Guest User

Untitled

a guest
Feb 21st, 2017
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.83 KB | None | 0 0
  1. # luna_pinyin.custom.yaml
  2. #
  3. # 【朙月拼音】模糊音定製模板
  4. # 佛振配製 :-)
  5. #
  6. # 位置:
  7. # ~/.config/ibus/rime (Linux)
  8. # ~/Library/Rime (Mac OS)
  9. # %APPDATA%\Rime (Windows)
  10. #
  11. # 於重新部署後生效
  12. #
  13.  
  14. patch:
  15. 'speller/algebra':
  16. - erase/^xx$/ # 第一行保留
  17.  
  18. # 模糊音定義
  19. # 需要哪組就刪去行首的 # 號,單雙向任選
  20. #- derive/^([zcs])h/$1/ # zh, ch, sh => z, c, s
  21. #- derive/^([zcs])([^h])/$1h$2/ # z, c, s => zh, ch, sh
  22.  
  23. #- derive/^n/l/ # n => l
  24. #- derive/^l/n/ # l => n
  25.  
  26. # 這兩組一般是單向的
  27. #- derive/^r/l/ # r => l
  28.  
  29. #- derive/^ren/yin/ # ren => yin, reng => ying
  30. #- derive/^r/y/ # r => y
  31.  
  32. # 下面 hu <=> f 這組寫法複雜一些,分情況討論
  33. #- derive/^hu$/fu/ # hu => fu
  34. #- derive/^hong$/feng/ # hong => feng
  35. #- derive/^hu([in])$/fe$1/ # hui => fei, hun => fen
  36. #- derive/^hu([ao])/f$1/ # hua => fa, ...
  37.  
  38. #- derive/^fu$/hu/ # fu => hu
  39. #- derive/^feng$/hong/ # feng => hong
  40. #- derive/^fe([in])$/hu$1/ # fei => hui, fen => hun
  41. #- derive/^f([ao])/hu$1/ # fa => hua, ...
  42.  
  43. # 韻母部份
  44. #- derive/^([bpmf])eng$/$1ong/ # meng = mong, ...
  45. #- derive/([ei])n$/$1ng/ # en => eng, in => ing
  46. #- derive/([ei])ng$/$1n/ # eng => en, ing => in
  47.  
  48. # 樣例足夠了,其他請自己總結……
  49.  
  50. # 反模糊音?
  51. # 誰說方言沒有普通話精確、有模糊音,就能有反模糊音。
  52. # 示例爲分尖團的中原官話:
  53. #- derive/^ji$/zii/ # 在設計者安排下鳩佔鵲巢,尖音i只好雙寫了
  54. #- derive/^qi$/cii/
  55. #- derive/^xi$/sii/
  56. #- derive/^ji/zi/
  57. #- derive/^qi/ci/
  58. #- derive/^xi/si/
  59. #- derive/^ju/zv/
  60. #- derive/^qu/cv/
  61. #- derive/^xu/sv/
  62. # 韻母部份,只能從大面上覆蓋
  63. #- derive/^([bpm])o$/$1eh/ # bo => beh, ...
  64. #- derive/(^|[dtnlgkhzcs]h?)e$/$1eh/ # ge => geh, se => sheh, ...
  65. #- derive/^([gkh])uo$/$1ue/ # guo => gue, ...
  66. #- derive/^([gkh])e$/$1uo/ # he => huo, ...
  67. #- derive/([uv])e$/$1o/ # jue => juo, lve => lvo, ...
  68. #- derive/^fei$/fi/ # fei => fi
  69. #- derive/^wei$/vi/ # wei => vi
  70. #- derive/^([nl])ei$/$1ui/ # nei => nui, lei => lui
  71. #- derive/^([nlzcs])un$/$1vn/ # lun => lvn, zun => zvn, ...
  72. #- derive/^([nlzcs])ong$/$1iong/ # long => liong, song => siong, ...
  73. # 這個辦法雖從拼寫上做出了區分,然而受詞典制約,候選字仍是混的。
  74. # 只有真正的方音輸入方案纔能做到!但「反模糊音」這個玩法快速而有效!
  75.  
  76. # 模糊音定義先於簡拼定義,方可令簡拼支持以上模糊音
  77. - abbrev/^([a-z]).+$/$1/ # 簡拼(首字母)
  78. - abbrev/^([zcs]h).+$/$1/ # 簡拼(zh, ch, sh)
  79.  
  80. # 以下是一組容錯拼寫,《漢語拼音》方案以前者爲正
  81. - derive/^([nl])ve$/$1ue/ # nve = nue, lve = lue
  82. - derive/^([jqxy])u/$1v/ # ju = jv,
  83. - derive/un$/uen/ # gun = guen,
  84. - derive/ui$/uei/ # gui = guei,
  85. - derive/iu$/iou/ # jiu = jiou,
  86.  
  87. # 自動糾正一些常見的按鍵錯誤
  88. - derive/([aeiou])ng$/$1gn/ # dagn => dang
  89. - derive/([dtngkhrzcs])o(u|ng)$/$1o/ # zho => zhong|zhou
  90. - derive/ong$/on/ # zhonguo => zhong guo
  91. - derive/ao$/oa/ # hoa => hao
  92. - derive/([iu])a(o|ng?)$/a$1$2/ # tain => tian
  93.  
  94. # 分尖團後 v => ü 的改寫條件也要相應地擴充:
  95. #'translator/preedit_format':
  96. # - "xform/([nljqxyzcs])v/$1ü/"
Add Comment
Please, Sign In to add comment