osfans / trime

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

librime未能正确处理shift组合键 #824

Closed tumuyan closed 5 months ago

tumuyan commented 2 years ago

Describe the bug 在同文调用librime时,实际上未能正确处理shift组合键。 按下软键盘时,使用直接发送字符的方式传值给librime,librime并没有直接处理按键事件,因此此时字母键打字正常,但是shift+数字和符号不能发送中文符号; 当使用实体键盘时,Shift+字母键也不能输入大写字母到编码区。

To Reproduce Steps to reproduce the bug:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See bug

Expected behavior Rime.onKey 正确处理shift键的组合键

Log If applicable, add crash log to quick focus your problem.

Screenshots If applicable, add screenshots to help explain your problem.

Smartphone (please complete the following information):

Additional context Add any other context about the problem here.

sbxlmdsl commented 1 year ago

但是,在同文3.2.10中,这些Shift组合键的输入在中文标点时是完全正常的,肯定是在3.2.11中引入的问题,而不是librime的问题。

sbxlmdsl commented 1 year ago

跟踪发现,这些Shift组合键在3.2.11中,根本就没有经过librime中的engine的ProcessKey处理,因为被keyCodeToVal判断成RimeKey_VoidSymbol了。

WhiredPlanck commented 5 months ago

现已修复。