HyDE-Project / Hyde-cli

A HyDE CLI, wrapper, tweaks , workarounds, and more!
https://github.com/prasanthrangan/hyprdots
GNU General Public License v3.0
106 stars 8 forks source link

bug: The vscode-oss can not work with Chinese input method #64

Closed CharlesIsMeee closed 5 months ago

CharlesIsMeee commented 5 months ago

Did you check docs and existing issues?

Hyde version

v0.5.2-2-g387cc6b

Operating system/version

Arch Linux x86_64 Kernel:6.9.1-arch1-1

Describe the bug

I can use fcitx5 to input Chinese with any Application but vscode-oss. When the cursor is in vscode-oss, if I press the ctrl+space, it would rise the code hinting of vscode-oss and fcitx5 would not toggle into Chinese input method. Even though I can toggle input method by cilcking the fcitx5 icon, it still couldn't input Chinese in vscode-oss. I have tried many methods such as add environment vars, add some launch args, change locale.conf and so on, however , nothing changed. 我在这里也能正常输入中文。

Steps To Reproduce

  1. After Hype install
  2. install fcitx5-im, fcitx5-chinese-addons, fcitx5-gtk, fcitx5-pinyin-moegirl, fcitx5-pinyin-material-color, fcitx5-pinyin-zhwiki
  3. add Chinese pinyin keyboard by fcitx5 configuration GUI application.
  4. try input Chinese in vscode-oss

Expected Behavior

When the input method toggle to the Chinese pinyin with vscode-oss, I could input Chinese into vscode-oss.

kRHYME7 commented 5 months ago

@CharlesIsMeee I'm not familiar with those things but I am sure this might not be related to the dotfiles.

Here is the repo for code-oss you can raise this issue their https://github.com/microsoft/vscode

I would assume that fcitx5 works except for that specific application code-oss.

CharlesIsMeee commented 5 months ago

@kRHYME7 Thanks a lot, I do find some similar issues there. There is a long history Chinese input bug with the snap version of VS code. As far as I learned, the fcitx5 works well with the .deb version of VS code. So I just selected and installed another release of VS code called vscodium-bin from aur package, and it works fine with my fcitx5 and I can enter Chinese into it now. So the version of VS code installed by HyDE maybe is the same version as the snap one. However, Thanks for your help.

kRHYME7 commented 5 months ago

@CharlesIsMeee Great!

Users preferred using code-oss over the vscode which I guess both have the same issues.

vscodium is from the linux community verison of vscode and I this is supported with Hyde theming too, so you'll be fine with it. Glad this is solved.

CharlesIsMeee commented 5 months ago

@kRHYME7 Finally, I found the best method to adress this issue. Just removing the command args --ozone-platform-hint=wayland from the file ~/.config/code-flags or appending the --enable-wayland-ime to the same file to run the electron application under the native Wayland with the fcitx5 which usually works under X11. Here is the wiki https://fcitx-im.org/wiki/Using_Fcitx_5_on_Wayland.I am very sorry that I did not discover this wiki earlier, which caused a waste of your valuable time. At the same time, thank you very much for your patient guidance