Bug 1850832 - The Gujarati & Hindi itrans methods are not able to type sentences correctly.
Summary: The Gujarati & Hindi itrans methods are not able to type sentences correctly.
Keywords:
Status: NEW
Alias: None
Product: Fedora
Classification: Fedora
Component: ibus-m17n
Version: 35
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: Mike FABIAN
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-06-25 02:01 UTC by Nirmal Pathak
Modified: 2022-11-29 16:48 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed:
Type: Bug


Attachments (Terms of Use)
Actual result while typing in GEdit using Gujarati and Hindi using itrans(m17n) input method. (213.23 KB, image/gif)
2020-06-25 02:01 UTC, Nirmal Pathak
no flags Details


Links
System ID Private Priority Status Summary Last Updated
GNOME Gitlab GNOME gtk merge_requests 4398 0 None merged gtk/imwayland: Use serial to control outbound messages 2022-09-20 03:48:11 UTC

Description Nirmal Pathak 2020-06-25 02:01:43 UTC
Created attachment 1698739 [details]
Actual result while typing in GEdit using Gujarati and Hindi using itrans(m17n) input method.

Description of problem:
The Gujarati & Hindi itrans methods are not able to type sentences correctly. When you start typing in Gujarati or Hindi using itrans(m17n) input method, the letters at times are replaced by 'space' or it simply doesn't print. At times, the special characters like "?" are printed before the previously typed/printed character.

This happens abruptly but in most cases, once you enter a new line by pressing 'enter' or 'return' key and start new sentence.

Version-Release number of selected component (if applicable):
m17n-db-1.8.0-9.fc32.noarch
ibus-m17n-1.4.2-2.fc32.x86_64
m17n-lib-1.8.0-7.fc32.x86_64

How reproducible:
Type in Gujarati or Hindi language using ibus itrans(m17n) method.


Steps to Reproduce:
1. Select Gujarati (itrans - m17n) or Hindi (itrans - m17n) method from ibus input method.
2. Start typing multiple sentences in Gujarati or Hindi.
3. Press 'enter' or 'return' key to start a new sentence in a new line.

Actual results:
- કે મછે?
- બરાબ રનથી લખાતું 
- कै से ?हो
- ऐसा क्युं छ परहा है? 

Expected results:
- કેમ છે?
- બરાબર નથી લખાતું 
- कैसे हो?
- ऐसा क्युं छप रहा है? 

Additional info:
Please check attached GIF image for actual results.

Comment 1 Mike FABIAN 2020-06-28 12:18:09 UTC
You are using Gnome Wayland, right?

Does this also happen when you use Gnome Xorg instead?

Comment 2 Mike FABIAN 2020-06-28 12:30:09 UTC
What does one usually (if everything works correctly) need to type to get these Gujarati and Hindi texts?
Is this correct: 

kema chhe? ➡️ કેમ છે?
kaise ho? ➡️ कैसे हो?

Comment 3 Nirmal Pathak 2020-06-28 12:36:36 UTC
(In reply to Mike FABIAN from comment #1)
> You are using Gnome Wayland, right?
> 

Yes, I am using GNOME Wayland.

> Does this also happen when you use Gnome Xorg instead?

I guess it happened once on GNOME Xorg as well. I tried on Xorg just now but couldn't reproduce this issue on GNOME Xorg.

(In reply to Mike FABIAN from comment #2)
> What does one usually (if everything works correctly) need to type to get
> these Gujarati and Hindi texts?
> Is this correct: 
> 
> kema chhe? ➡️ કેમ છે?
> kaise ho? ➡️ कैसे हो?

Yes, the above outputs in Gujarati & Hindi are correct.

Comment 4 Mike FABIAN 2020-06-28 13:09:37 UTC
I think it is caused by bugs in the ibus-support in Gnome wayland.
Several input methods suffer from this, ibus-hangul as well.

Comment 5 Mike FABIAN 2020-06-28 13:24:08 UTC
On Gnome Xorg it works for me all the time.

On Gnome Wayland if fails almost always.

Do you know that gu-itrans and hi-itrans can also be used with ibus-typing-booster?

ibus-typing-booster seems to suffer less from this bug in Wayland than ibus-m17n,
I just tried gu-itrans and hi-itrans in Gnome Wayland on F32 and the two strings:

kema chhe? ➡️ કેમ છે?
kaise ho? ➡️ कैसे हो?

worked for me all the time.

ibus-typing-booster also sometimes suffers from this wayland bug, sometimes the spaces used to commit are inserted in a wrong positon. But in case of gu-itrans and hi-itrans it seems to be quite rare, at least rare enough that I could not reproduce it.

Here you can see how to setup ibus-typing-booster to use hi-itrans and gu-itrans:

http://mike-fabian.github.io/ibus-typing-booster/documentation.html#setup-dictionaries-input-methods

Just press the + button below the list of input methods and add hi-itrans and/or gu-itrans.

If you add both, you can switch between them using the Gnome panel or the keyboard shortcut for the "next_input_method"
command (By default Control+Down, can be changed in the setup tool).

ibus-typing-booster has more features than ibus-m17n, it can complete words and learn from user input.
But even if you don’t want any of the additional features, you could still use ibus-typing-booster instead of
ibus-m17n and disable all the extra features as described here:

http://mike-fabian.github.io/ibus-typing-booster/documentation.html#simulate-ibus-m17n

Comment 6 Nirmal Pathak 2020-06-29 04:47:33 UTC
Thanks for pointing me to the 'ibus-typing-booster' along with its documentation. 

I used 'ibus-typing-booster' and was able to reproduce the issue with 'hi-itrans' after writing a few sentences however it seems to be quite rare as mentioned above.

Comment 7 Mike FABIAN 2020-06-29 06:52:29 UTC
Can you also please try to update to the packages in this testing repository?:

https://copr.fedorainfracloud.org/coprs/pwu/wayland/packages/

They contain some fixes which seem to help a lot with this problem.
After installing the updates from this repo, I can still reproduce the problem, but it seems to occur less often.

Comment 8 Nirmal Pathak 2020-06-30 13:55:16 UTC
I enabled the 'copr' repo of "pwu/wayland" on my system but cannot find "wayland-protocols" package.


-- output --
$ sudo dnf copr enable pwu/wayland

$ sudo dnf update gnome-shell-3.36.3-4.fc32 gtk3-3.24.20-2.fc32 mutter-3.36.3-5.fc32.x86_64 wayland-protocols-1.20-2.fc32
Last metadata expiration check: 0:00:59 ago on Tuesday 30 June 2020 07:18:11 PM.
Package wayland-protocols available, but not installed.
No match for argument: wayland-protocols-1.20-2.fc32
Dependencies resolved.
=============================================================================================================================================
 Package                          Architecture                Version                              Repository                                                       Size
=============================================================================================================================================
Upgrading:
 gnome-shell                      x86_64                      3.36.3-4.fc32                        copr:copr.fedorainfracloud.org:pwu:wayland                      1.5 M
 gtk3                             x86_64                      3.24.20-2.fc32                       copr:copr.fedorainfracloud.org:pwu:wayland                      4.7 M
 mutter                           x86_64                      3.36.3-5.fc32                        copr:copr.fedorainfracloud.org:pwu:wayland                      2.4 M

Transaction Summary
-- output --

Comment 9 Mike FABIAN 2021-01-12 06:39:31 UTC
I can still reproduce this on f33.

Comment 10 fujiwara 2021-01-15 01:09:42 UTC
@Nirmal Pathak:

Could you please check if you can reproduce your issue in Fedora 33?
Fedora 33 is enhanced about the input in GNOME Wayland and I'd like to know if your problem is identified accurately.

Comment 11 Nirmal Pathak 2021-01-16 09:55:12 UTC
I tried typing using iTrans Hindi & Gujarati but I don't see much improvement on Wayland.

Actual results:
- સ્પે છોડાતી નથી? અક્ષર ભૂંસાઈ જાય છે.

- कै हो?

Expected results:
- સ્પેસ છોડાતી નથી? અક્ષર ભૂંસાઈ જાય છે.

- कैसे हो?

The moment I press the spacebar the last letter is effaced automatically at times.

Comment 12 Mike FABIAN 2021-10-05 07:27:17 UTC
Yes, the problem is still there in Gnome Wayland on Fedora 35 (Fedora-Workstation-Live-x86_64-35-20210829.n.0.iso installed in qemu-kvm with all current updates)

Comment 14 Mike FABIAN 2021-10-14 07:08:35 UTC
It works on Gnome Xorg but not on Gnome Wayland.

On Gnome Wayland it can be easily reproduced by using ibus-m17n with m17n:gu:itrans and they type "ho ".

The result of typing "ho " should be "હો".

But sometimes the characters disappears on commit.

Comment 15 Mike FABIAN 2021-10-14 07:40:56 UTC
When using Peng Wu’s patch from https://gitlab.gnome.org/GNOME/gtk/-/merge_requests/3404 the problem disappears.

Comment 16 Mike FABIAN 2022-09-19 15:05:27 UTC
It looks like I cannot reproduce this on Gnome Wayland in Fedora 37 anymore, even though Peng Wu’s patch seems not to have been merged.

Comment 17 Peng Wu 2022-09-20 03:48:12 UTC
I think there is another patch merged in upstream.

Comment 18 Ben Cotton 2022-11-29 16:48:59 UTC
This message is a reminder that Fedora Linux 35 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora Linux 35 on 2022-12-13.
It is Fedora's policy to close all bug reports from releases that are no longer
maintained. At that time this bug will be closed as EOL if it remains open with a
'version' of '35'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, change the 'version' 
to a later Fedora Linux version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora Linux 35 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora Linux, you are encouraged to change the 'version' to a later version
prior to this bug being closed.


Note You need to log in before you can comment on or make changes to this bug.