Leon0824 / rimeime

Automatically exported from code.google.com/p/rimeime
0 stars 0 forks source link

自製輸入方案無法用字母選字 #499

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
自製了一個輸拼音出注音的輸入方案,由於聲調要用12345所以
只能用字母選字,加了alternative_select_keys: 
"QWERTYUIOP",之後雖然候選字列表中的標號已經變成了“Q.”“
W.”等,但按Q、W等時卻會在輸入框(不是上屏後的文本框)�
��原樣顯示出來,根本起不到選字等作用。我把同樣字母選字
等注音輸入方案的processors和menu完全照抄(除了改動ABCDEFGHIJ��
�QWETYUIOP),卻仍然沒有效果。請問是怎麼回事,如何解決?

附:自製輸入方案的schema文件
# Rime schema
# encoding: utf-8

schema:
  schema_id: pinyin_to_bopomofo
  name: 拼音轉注音
  version: "0.1"
  author:
    - jack980517 <jack980517@gmail.com>
  description: |
    爲了防止我輸入錯誤的注音,同時保證輸入速度,特制定此schema。

switches:
  - name: ascii_mode
    reset: 0
    states: [ 中文, 西文 ]
  - name: full_shape
    states: [ 半角, 全角 ]

engine:
  processors:
    - ascii_composer
    - recognizer
    - key_binder
    - speller
    - punctuator
    - selector
    - navigator
    - express_editor
  segmentors:
    - ascii_segmentor
    - matcher
    - abc_segmentor
    - punct_segmentor
    - fallback_segmentor
  translators:
    - punct_translator
    - table_translator@custom_phrase
    - script_translator

menu:
  alternative_select_keys: "QWERTYUIOP"

speller:
  alphabet: zyxwvutsrqponmlkjihgfedcba12345
  initials: zyxwvutsrqponmlkjihgfedcba
  finals: 12345
  delimiter: " '"
  algebra:
    - erase/^xx$/
    - abbrev/^([a-z]).+$/$1/
    - abbrev/^([zcs]h).+$/$1/
    - derive/^([nl])ve$/$1ue/
    - derive/^([jqxy])u/$1v/
    - derive/un$/uen/
    - derive/ui$/uei/
    - derive/iu$/iou/
    - derive/([aeiou])ng$/$1gn/
    - derive/([dtngkhrzcs])o(u|ng)$/$1o/
    - derive/ong$/on/
    - derive/ao$/oa/
    - derive/([iu])a(o|ng?)$/a$1$2/

translator:
  dictionary: pinyin_to_bopomofo
  preedit_format:
    - xform/([nl])v/$1ü/
    - xform/([nl])ue/$1üe/
    - xform/([jqxy])v/$1u/

custom_phrase:
  dictionary: ""
  user_dict: custom_phrase
  db_class: stabledb
  enable_completion: false
  enable_sentence: false
  initial_quality: 1

punctuator:
  import_preset: default

key_binder:
  import_preset: default

recognizer:
  import_preset: default
  patterns:
    reverse_lookup: "`[a-z]*'?$"

1. 輸入法的款式:小狼毫
   輸入法版本號:0.9.26

2. 操作系統類型:Linux / Mac / Windows
   操作系統版本:XP SP3

3. 輸入方案名稱:(如果問題涉及交互方式、輸入效果等
,請填寫)自製的“拼音轉注音”

Original issue reported on code.google.com by jack980...@gmail.com on 21 Oct 2013 at 4:39

GoogleCodeExporter commented 9 years ago
*更正:“……根本起不到選字的作用。我把同樣字母選字的�
��音輸入方案……”
還有,操作系統是Windows XP SP3

Original comment by jack980...@gmail.com on 21 Oct 2013 at 4:41

GoogleCodeExporter commented 9 years ago
recognizer:
  import_preset: default
其中包含將大寫字母直接輸出爲文字的規則。請刪除上方這��
�行代碼。

其實現爲
https://github.com/lotem/brise/blob/master/default.yaml#L134

Original comment by contral...@gmail.com on 21 Oct 2013 at 6:36