Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: avoid input issues in some apps #1411

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

CDHJS
Copy link

@CDHJS CDHJS commented Oct 26, 2024

注释掉了Composition.cpp中的pRangeComposition->SetText(ec, TF_ST_CORRECTION, L" ", 1);

pRangeComposition->SetText(ec, TF_ST_CORRECTION, L" ", 1);

可避免Firefox系浏览器部分情况无法输入问题 #1144
可能也能解决 #1406 所提到的部分问题

@mirtlebot
Copy link

/* WORKAROUND:
* CUAS does not provide a correct GetTextExt() position unless the
* composition is filled with characters. So we insert a zero width space
* here. The workaround is only needed when inline preedit is not enabled.
* See https://github.com/rime/weasel/pull/883#issuecomment-1567625762
*/

这个空格是什么情况下有用?我试着去掉空格编译了一下,Chrome、Notepad 等应用都是正常定位的,是有些应用不行吗 @fxliang

@fxliang
Copy link
Contributor

fxliang commented Oct 28, 2024

/* WORKAROUND:
* CUAS does not provide a correct GetTextExt() position unless the
* composition is filled with characters. So we insert a zero width space
* here. The workaround is only needed when inline preedit is not enabled.
* See https://github.com/rime/weasel/pull/883#issuecomment-1567625762
*/

这个空格是什么情况下有用?我试着去掉空格编译了一下,Chrome、Notepad 等应用都是正常定位的,是有些应用不行吗 @fxliang

这个旧代码一直都是空格,我是试过改成零宽空格但是不太好用后来又改回空格了。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants