Bug 13170 - MCC (control centre) localization bug - IBus IM not working with chromium-browser.
Summary: MCC (control centre) localization bug - IBus IM not working with chromium-bro...
Status: RESOLVED OLD
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: 4
Hardware: x86_64 Linux
Priority: Normal normal
Target Milestone: ---
Assignee: Mageia Bug Squad
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 11709
  Show dependency treegraph
 
Reported: 2014-04-08 11:39 CEST by Edward d'Auvergne
Modified: 2015-10-27 06:57 CET (History)
2 users (show)

See Also:
Source RPM:
CVE:
Status comment:


Attachments

Description Edward d'Auvergne 2014-04-08 11:39:52 CEST
Description of problem:

This is part of a series of IBus and MCC localization bugs (Skype and 32-bit software https://bugs.mageia.org/show_bug.cgi?id=13168, Libreoffice https://bugs.mageia.org/show_bug.cgi?id=13169).

The IBus IM system does not work by default with the chromium-browser package.  I do not know how to configure IBus to work with the 'Views' Chromium's UI toolkit.  But this should be done by MCC localization wizard automatically for the user.

Reproducible: 

Steps to Reproduce:
Comment 1 Edward d'Auvergne 2014-04-08 17:41:36 CEST
The fix for this bug is as mentioned in https://bugs.mageia.org/show_bug.cgi?id=13171#c1, simply set the GTK_IM_MODULE_FILE environmental variable.  Testing on a 64-bit system works.  But for some reason in a 32-bit Mageia 4 virtualbox image this fix does not work.  This probably indicates that the following fix is only part of the solution and that something else is required.

For the 64-bit system, install the lib64gtk+2.0_0 package.  Then IBus will work with:

$ GTK_IM_MODULE_FILE=/etc/gtk-2.0/gtk.immodules.lib64 /usr/bin/chromium-browser

To make this permanent for all users, add the following line to /etc/profile:

export GTK_IM_MODULE_FILE=/etc/gtk-2.0/gtk.immodules.lib64
Comment 2 Edward d'Auvergne 2014-04-08 19:23:32 CEST
There is one additional step needed to fix this problem on both 32 and 64-bit systems.  The following two commands must be issued every time you log in:

$ ibus exit
$ ibus-daemon -x -d &

Together with the GTK_IM_MODULE_FILE environmental variable, you will then be able to use IBus with chromium-browser.  This is the same bug and fix as for firefox (https://bugs.mageia.org/show_bug.cgi?id=8731).  The above two commands are not needed for the gvim IBus bug (https://bugs.mageia.org/show_bug.cgi?id=13171).
Comment 3 Ethan Merritt 2014-04-08 20:09:16 CEST
Rather than issuing such a command every time you log in, check that you have the following script in place (I honestly don't recall whether this came from an installation package or whether I added it manually):

cat ${HOME}/.kde4/Autostart/ibus-daemon-autostart.sh
#!/bin/sh
ibus-daemon -d -x -r -n kde

CC: (none) => eamerritt

Comment 4 Edward d'Auvergne 2014-04-09 10:32:41 CEST
Hi Ethan,

I tried the ~/.kde4/Autostart/ibus-daemon-autostart.sh shell script, making it executable, but it did nothing.  I still had to kill the ibus daemon and restart it.

As set up by default and correctly in Mageia, I have the following environmental variables for all users:

$ env | grep ibus | sort
GTK_IM_MODULE=ibus
QT_IM_MODULE=ibus
XIM_PROGRAM=ibus-daemon -d -x
XMODIFIERS=@im=ibus

Therefore IBus is already running when I log in:

$ ps -ef | grep ibus
edward    1619     1  0 08:38 ?        00:00:27 /usr/bin/ibus-daemon-real -d -x
edward    1653  1619  0 08:38 ?        00:00:00 /usr/libexec/ibus-dconf
edward    1657  1619  0 08:38 ?        00:00:04 /usr/libexec/ibus-ui-gtk3
edward    1667     1  0 08:38 ?        00:00:00 /usr/libexec/ibus-x11 --kill-daemon
edward    1775  1619  0 08:38 ?        00:00:07 /usr/libexec/ibus-engine-simple
edward    1780  1619  0 08:38 ?        00:00:00 /usr/libexec/ibus-engine-pinyin --ibus
edward    3678  2529  0 10:07 pts/10   00:00:00 grep --color ibus

This is why the 'ibus exit' command is needed - to kill the current IBus daemon which is not registering in chromium-browser and firefox.  Restarting the daemon fixes it.  But running 'ps -ef | grep ibus' shows exactly the same output (but with different PIDs of course).  This is also not a difference between /usr/bin/ibus-daemon-real binary and /usr/bin/ibus-daemon shell script which calls it, as running the following also fixes the problem:

$ ibus-daemon-real -x -d &

And the "-n kde" option is not a solution as I can add the following line to /etc/profile:

export XIM_PROGRAM=ibus-daemon -d -x -n kde

But this does not solve the problem and the option appears to do nothing.

All of this indicates that this is an IBus start up sequence bug.
Comment 5 Edward d'Auvergne 2014-04-09 11:16:54 CEST
The following executable ~/.kde4/Autostart/ibus-daemon-restart.sh shell script does provide a good workaround for the bug:

$ ls -lhG ~/.kde4/Autostart/ibus-daemon-restart.sh
-rwxr-xr-x 1 edward 38 Apr  9 10:56 /home/edward/.kde4/Autostart/ibus-daemon-restart.sh*

$ cat ~/.kde4/Autostart/ibus-daemon-restart.sh
#!/bin/sh
ibus exit
ibus-daemon -d -x

Note that it must be executable.  I do not know why the ibus-daemon replace command line option '-r' in your script Ethan does not do the same thing!
Comment 6 Edward d'Auvergne 2014-04-14 09:18:43 CEST
As mentioned by 'a b' in https://bugs.mageia.org/show_bug.cgi?id=8731#c35, the GTK_IM_MODULE_FILE environmental variable is fatal for GTK3 software.  When set, try:

$ evince
Segmentation fault
$

This results in Gnome and all Gnome software being totally unusable.  If chromium-browser (or firefox) is started as:

$ GTK_IM_MODULE_FILE=/etc/gtk-2.0/gtk.immodules.lib64 /usr/bin/chromium-browser

Then chromium-browser (or any other GTK2 software) cannot launch any GTK3 programs.  Therefore this is not a proper solution.
Comment 7 Edward d'Auvergne 2015-02-06 20:00:33 CET
This is working on a default install of Mageia 5, beta 2.
Edward d'Auvergne 2015-02-06 20:04:54 CET

Blocks: (none) => 11709

Edward d'Auvergne 2015-02-07 10:48:39 CET

CC: (none) => true.bugman

Comment 8 Samuel Verschelde 2015-09-21 13:19:58 CEST
Mageia 4 changed to end-of-life (EOL) status on 2015-09-19. It is is no longer 
maintained, which means that it will not receive any further security or bug 
fix updates.

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

Bug Reporter: Thank you for reporting this issue and we are sorry that we weren't 
able to fix it before Mageia 4's end of life. If you are able to reproduce it 
against a later version of Mageia, you are encouraged to click on "Version" and 
change it against that version of Mageia. If it's valid in several versions, 
select the highest and add MGAxTOO in whiteboard for each other valid release.
Example: it's valid in cauldron and Mageia 5, set to cauldron and add MGA5TOO.

Although we aim to fix as many bugs as possible during every release's lifetime, 
sometimes those efforts are overtaken by events. Often a more recent Mageia 
release includes newer upstream software that fixes bugs or makes them obsolete.

If you would like to help fixing bugs in the future, don't hesitate to join the
packager team via our mentoring program [1] or join the teams that fit you 
most [2].

[1] https://wiki.mageia.org/en/Becoming_a_Mageia_Packager
[2] http://www.mageia.org/contribute/
Comment 9 Marja Van Waes 2015-10-27 06:57:14 CET
As announced over a month ago, Mageia 4 changed to end-of-life (EOL) status on 2015-09-19. It is is no longer maintained, which means that it will not receive any further security or bug fix updates.

This issue may have been fixed in a later Mageia release, so, if you still see it and didn't already do so: please upgrade to Mageia 5 (or, if you read this much later than this is written: make sure you run a currently maintained Mageia version)

If you are able to reproduce it against a maintained version of Mageia, you are encouraged to 
1. reopen this bug report, by changing the "Status" from "RESOLVED - OLD" to "REOPENED"
2. click on "Version" and change it against that version of Mageia. If you know it's valid in several versions, select the highest and add MGAxTOO in whiteboard for each other valid release.
Example: it's valid in cauldron and Mageia 5, set to cauldron and add MGA5TOO.
3. give as much relevant information as possible. If you're not an experienced bug reporter and have some time: please read this page:
https://wiki.mageia.org/en/How_to_report_a_bug_properly

If you see a similar issue, but are _not_sure_ it is the same, with the same cause, then please file a new bug report and mention this one in it (please include the bug number, too). 


If you would like to help fixing bugs in the future, don't hesitate to join the
packager team via our mentoring program [1] or join the teams that fit you 
most [2].
[1] https://wiki.mageia.org/en/Becoming_a_Mageia_Packager
[2] http://www.mageia.org/contribute/

Status: NEW => RESOLVED
Resolution: (none) => OLD


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