osfans / trime

同文安卓輸入法平臺3.x/Android-rime/Rime Input Method Engine for Android
http://osfans.github.io/trime/
GNU General Public License v3.0
3.08k stars 372 forks source link

剥离方案、键盘配列和键盘label的对应关系 #827

Open tumuyan opened 2 years ago

tumuyan commented 2 years ago

Is your feature request related to a problem? Please describe. 现状:如果主题没有设计方案对应的键盘,无法显示方案对应的配列和label

Describe the solution you'd like 剥离方案、键盘配列和键盘label的对应关系,主题包含若干配列,使用一个单独的yaml文件保存按键和label的对应关系,在方案中增加配列、label名称。 这样每个主题都只需要设计固定数量的主键盘,就可以适配大多数输入方案; 键盘label可以根据用户喜好自由定义;

Additional context 关联 #738

tumuyan commented 2 years ago
  1. 每个主题都需要预设如下主键盘配列(点击即触发): qwerty 基本字母(26字母+,.) qwerty0 基本字母+数字 qwerty 30键 基本字母+一类符号,./;
    qwerty0
    40键 基本字母+一类符号,./;
    qwerty0_= 基本字母+一类符号+二类符号 (考虑到屏幕尺寸,可以不设计此配列,而是使用importpreset: qwerty0 ) 123 默认为中文的数字键盘

包含基本字母的主键盘配列,需要设计通过长按组合的方式,覆盖图中着色的全部按键 不在一类符号内,建议通过composing的方式实现点击即触发 可以使用import_preset 的写法,减少工作量

参考图 trime-keyboard-layout-class (2)

  1. 倡议主键盘的常规字母、数字、符号按键不设置按键label,从keyboard.yaml中自动解析
tumuyan commented 2 years ago

keyboard.zip

InfinityLoop1308 commented 2 years ago

Good, but IMO it totally depends on the author. As most of the themes are legacies, there may not be many changes.