IBBoard / cawbird

A fork of the Corebird GTK Twitter client that continues to work with Twitter
https://ibboard.co.uk/cawbird/
GNU General Public License v3.0
309 stars 37 forks source link

Mozc IME input broken in Cawbird #376

Closed Asday closed 3 years ago

Asday commented 3 years ago

Describe the bug The Mozc IME doesn't appear to work in Cawbird.

To Reproduce Steps to reproduce the behavior:

  1. Install the Japanese Mozc IME
  2. Switch to it by clicking on it in the status bar and switching from (probably) "English - English US" to "Japanese - Mozc"
  3. Click it again and switch the input mode to hiragana (あ)
  4. In any textbox, (the URL bar of your browser works nicely, as does gedit), type something like "ka" and see that it turns into 「か」 with an underline and a popup showing suggestions
  5. In the compose tweet textbox in Cawbird, type the same and see that it just comes out as roman letters.

Expected behavior The IME should be used in the same way as in all other text inputs on the system.

System details:

Additional context Cawbird doesn't appear to mind the Japanese characters themselves - typing out my tweets in a text editor and copy pasting them works fine, it's just the IME that's being broken somehow.

IBBoard commented 3 years ago

This should all just be handled by GTK. But maybe our auto-complete behaviour messes it up. This could be tricky to debug as I've never looked at IME before.

Asday commented 3 years ago

Let me know if you hit a wall of some sort - I haven't yet installed the IME on my laptop (Manjaro), so I can take it slow and muck around.

IBBoard commented 3 years ago

Struggling to test this so far. I've got ibus-mozc installed and added "Japanese - Mozc" as another input method, but the "Next input method" shortcut doesn't seem to trigger anything!

Screenshot from 2021-04-27 20-13-08

More investigating required before I can investigate this, I guess.

[Edit] Ahah! I need to do it via Gnome Settings > Keyboard rather than ibus-setup! (pointer from https://bbs.archlinux.org/viewtopic.php?id=165385)

IBBoard commented 3 years ago

Hmmm, seems to work for me on openSUSE Tumbleweed.

ibus 1.5.24, ibus-mozc 2.26.4276.102, GTK 3.24.27.

https://user-images.githubusercontent.com/388582/116300522-e3941d80-a796-11eb-818a-ec4806f4b68e.mp4

Asday commented 3 years ago

So my versions are a little behind yours, I'm going to have to figure out why they're not turning up in my list of updates to apply and get them updated, and report back - thanks for your patience so far.

IBBoard commented 3 years ago

Different distros ship different versions. openSUSE Tumbleweed is a rolling distro, so it's always up-to-date. Ubuntu-based distros tend to stick with a version from release and just backport security patches.

So, it could be that the older version conflicts in some odd way that newer versions don't. But it would seem unusual.

I briefly wondered whether it was a clash from us using Tab as the auto-complete for snippets, but if it's just showing Latin characters and not converting then that's before Tab would interfere.

Does it work in any input boxes in Cawbird or is it broken in all of them? There's tweet composing, DM composing, image description, profile description, search, and list editing (and possibly more!)

Asday commented 3 years ago

I tried all of those and it's working in none of them. I also alt-tabbed to my terminal inbetween each to make sure Mozc was still awake and working, and it was.

I just set up Mozc on my laptop, but it's going through (hosted by?) fcitx5 instead, and works just fine.

If you could give me a gentle push in the way of how to upgrade my Mozc adn IBus on my Mint install (basically ubuntu), I can investigate further.

IBBoard commented 3 years ago

There's probably no way to upgrade them on Mint. The distro releases the versions that it releases, so as long as you're up-to-date with all of your updates then you've got the latest version that your distro supplies.

I'd expect more issues with fcitx5, though. ibus is core to Gnome whereas fcitx5 would seem to be trying to replace some of that tightly integrated infrastructure (although I don't know the details of IMEs, so maybe it's not tha bad).

IBBoard commented 3 years ago

I've tried looking around for bug reports in Mozc but can't find anything relevant. Since it's working for you on another device using fcitx5 then I think I'm going to have to close this as not being something that we can fix.

Asday commented 3 years ago

Yeah I'm overdue to nuke this install and replace it with something else, and Manjaro's trial run on my laptop has been mega sweet so I'll just switch to that I think.

Other bizarre symptoms include - Cawbird straight up refuses to go into dark mode. To any future googler's arriving here, I'm sorry I didn't have the motivation to investigate further. Good luck.

IBBoard commented 3 years ago

Not doing dark mode normally means you've not got a dark theme. It uses built-in GTK requests and should work with Adwaita out of the box.

If you're using the Flatpak or anything else then you need a special addition (even if you've got the dark theme on the rest of your system… because Flatpak). I don't know how it plays with some distro's custom themes. I think it depends on how they implemented it.