ibus breaks emacs and eclipse control-space keybinding

Bug #1278569 reported by Barry Warsaw
206
This bug affects 43 people
Affects Status Importance Assigned to Milestone
emacs24 (Debian)
Fix Released
Unknown
ibus (Ubuntu)
Triaged
High
Unassigned

Bug Description

Installing ibus 1.5.5-1ubuntu1 breaks Emacs 24's control-space keybinding. I generally have that bound to a custom lisp function, but by default (e.g. starting with `emacs -Q`) it is bound to set-mark-command. After doing a dist-upgrade in Trusty which installs ibus 1.5.5-1ubuntu1, emacs no longer even sees the control-space key chord. My guess is that ibus is consuming this event, preventing emacs from seeing it. This is a critical regression that makes emacs almost unusable.

By process of elimination, I've narrowed it down to one of these 4 binary packages.

gir1.2-ibus-1.0
ibus
ibus-gtk
ibus-gtk3

ProblemType: Bug
DistroRelease: Ubuntu 14.04
Package: ibus 1.5.5-1ubuntu1
ProcVersionSignature: Ubuntu 3.13.0-8.27-generic 3.13.2
Uname: Linux 3.13.0-8-generic x86_64
ApportVersion: 2.13.2-0ubuntu2
Architecture: amd64
CurrentDesktop: Unity
Date: Mon Feb 10 15:15:57 2014
EcryptfsInUse: Yes
InstallationDate: Installed on 2013-12-06 (66 days ago)
InstallationMedia: Ubuntu 13.10 "Saucy Salamander" - Release amd64 (20131016.1)
SourcePackage: ibus
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Barry Warsaw (barry) wrote :
Revision history for this message
Barry Warsaw (barry) wrote :

``sudo apt-get purge ibus` and a reboot restores the emacs functionality.

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in ibus (Ubuntu):
status: New → Confirmed
Revision history for this message
Aron Xu (happyaron) wrote :

Can you please try whether updating to ibus 1.5.5-1ubuntu2 solves the problem?

Revision history for this message
Alberto Salvia Novella (es20490446e) wrote :

It renders essential features or functionality of the package (or a dependent one) broken.

Changed in ibus (Ubuntu):
importance: Undecided → High
Revision history for this message
Christopher Barrington-Leigh (cpbl) wrote :

I have just done an update, and rebooted, and the functionality of Ctrl-space in emacs is restored. (14.04LTS)

Revision history for this message
Walter Garcia-Fontes (walter-garcia) wrote :

With 1.5.5-1ubuntu2 the problem does not show up. Is any of the affected users still seeing the problem?

Changed in ibus (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Hadmut Danisch (hadmut) wrote :

Yup, I'm still having the problem with ibus 1.5.5-1ubuntu2

Revision history for this message
Walter Garcia-Fontes (walter-garcia) wrote :

hadmut, since most affected users seem to be fine with the update to ibus, it may be convenient that you open a report with "ubuntu-bug ibus" to have information about your system

Revision history for this message
Barry Warsaw (barry) wrote : Re: [Bug 1278569] Re: ibus breaks emacs24 control-space keybinding

On Mar 14, 2014, at 06:30 AM, Walter Garcia-Fontes wrote:

>hadmut, since most affected users seem to be fine with the update to
>ibus, it may be convenient that you open a report with "ubuntu-bug ibus"
>to have information about your system

FTR, I "solved" this by uninstalling ibus. It's not something I ever used
(afaict).

Revision history for this message
Hadmut Danisch (hadmut) wrote : Re: ibus breaks emacs24 control-space keybinding

@Walter:

> it may be convenient that you open a report with "ubuntu-bug ibus"

That's what I started with.

Then someone came, marked my report #1289570 as a duplicate of this bug. Now you are asking me to open a report...

I solved the problem simply be removing ibus as Barry proposed. It helps.

Actually ibus seems to be useless and to not do anything good, just harm. System runs better without it. Ironically, the package description does not contain the slightest hint about what ibus should be good for or what use it would have.

After all, what's the reason for having ibus in the system? What is it? What does it do, beyond disturbing keyboard input?

Revision history for this message
Walter Garcia-Fontes (walter-garcia) wrote :

@hadmut, sorry I didn't see your bug had been duplicated here, you can unduplicate it yourself if you want to reopen it.

As for ibus, it's a Debian package used for input in Linux systems. I don't know if there are going to be any side effects of removing the package. For instance:

https://packages.debian.org/sid/ibus

Revision history for this message
Herbert V. Riedel (hvr) wrote :

I just experienced this issue after upgrading to Trusty; I solved it by calling `ibus-setup` and deleting the key-binding

Changed in ibus (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
Florian Hars (hars) wrote :

Still not fixed with 1.5.5-1ubuntu3

Revision history for this message
anders.olme@gmail.com (anders-olme) wrote :

got the same problem but only in kde desktop not when loading ubuntu/unity desktop.

Revision history for this message
flg (flg) wrote :

Same problem here. Version : 1.5.5-1ubuntu3

FTR, I experienced the problem with completion in Eclipse (which is bound to CTRL+space).

ibus-setup and deleting the keybinding as suggested by Herbert worked perfectly (thanks).

Revision history for this message
Jesse Glick (jesse-glick) wrote :

Confirmed, removing the keybinding from ibus-setup worked with 1.5.5-1ubuntu3 (current latest in XUbuntu 14.04). This was a poor choice for a default keybinding—used not only by Emacs, but by most IDEs, such as NetBeans.

Revision history for this message
Jarl (jarl-dk) wrote :

I confirm this is a problem with default installation of ibus version 1.5.5-1ubuntu3

Revision history for this message
Balázs Úr (urbalazs) wrote :

This workaround fix it for me:
Run the "ibus exit" command in a termial.

Revision history for this message
Margarita Manterola (marga-9) wrote :

Indeed, the problem was "fixed" for Unity, by special-casing it. Every other desktop environment is affected by this bug in Trusty.

Debian has switched the default key from Ctrl-Space to Super-Space. This should be done for Trusty as well, since ibus is getting installed by default and getting in the way of a lot of people's workflows.

summary: - ibus breaks emacs24 control-space keybinding
+ ibus breaks emacs and eclipse control-space keybinding
Revision history for this message
Fredrik Wendt (fredrik-wendt) wrote :

I'm looking for an automated way to either disable ibus, or change the mapping (or remove it). All our developer vagrant images are based on lubuntu 14.04 (and have emacs and eclipse installed). This is the last single thing we haven't found a way to fix yet.

Revision history for this message
Fredrik Wendt (fredrik-wendt) wrote :

The workaround used now is to run "ibus exit" in .config/lxsession/Lubuntu/autostart

Revision history for this message
Ethan Gold (ethan-gold-3000) wrote :

After reading this thread I looked throught settings menu in XFCE4 and launched the "Keyboard Input Methods" control panel. Right there you can delete the key binding in the GUI, which is used to toggle between input methods. More of a bad configuration default than a bug.

Revision history for this message
Aron Xu (happyaron) wrote :

I think this is caused by setting Ctrl-Space as the default shortcut in ibus-setup's default configuration, that's a diff between Ubuntu and Debian because there was problem in switching the input method in Unity (where Super-Space is captured by gnome/unity-settings-daemon). I'll see if we can drop that with recent gnome/unity-settings-daemon updates.

Revision history for this message
Jonathan Paul (jonathan8paul) wrote :

This not only is affecting eclipse users, it's affecting people of all different types of programs, including Minecraft players. It causes the player to not be able to sprint (ctrl) and jump (space) at the same time.

Revision history for this message
Aron Xu (happyaron) wrote :

For MineCraft, there is problem in its keyboard handling code and no input method is working with it, including other input fields within the program cannot be working. It's a different issue that should be handled by MineCraft.

Aron Xu (happyaron)
Changed in ibus (Ubuntu):
status: Confirmed → Triaged
Revision history for this message
Jorge Suárez de Lis (ys) wrote :

I'm unable to setup a different keybinding system-wide.

There is a file describing the dconf schema with the default values: /usr/share/glib-2.0/schemas/org.freedesktop.ibus.gschema.xml

I tried changing this:

<key type="as" name="triggers"><default>[ '&lt;Control&gt;space' ]</default><summary>Trigger shortcut keys for gtk_accelerator_parse</summary><description>The shortcut keys for turning input method on or off</description></key>

To this:

<key type="as" name="triggers"><default>[ '&lt;Control&gt;&lt;Super&gt;space' ]</default><summary>Trigger shortcut keys for gtk_accelerator_parse</summary><description>The shortcut keys for turning input method on or off</description></key>

I can see the change in dconf-editor. If I set the value to the default, I get ['<Control><Super>space'] and the bold style on the key is removed.

But when I enter ibus-setup, the old default <Control>space is shown instead. Changing the value to <Control><Super>space inside ibus-setup, also makes changes that I can see in dconf-editor. The value is not set to the default (bold style in key), and the very same ['<Control><Super>space'] string is shown.

If I press the "Reset to defaults" button in dconf-editor, the value is set to the default (the bold style on the key is gone). The string is still the same ['<Control><Super>space']

Then, If I enter ibus-setup again, <Control>space is shown.

I should be able to setup a different system-wide keybinding by changing this file, shouldn't I? Should I file a bug report?

Revision history for this message
era (era) wrote :

Based on earlier suggestions, I worked around this by changing the keybinding to <Ctrl><Alt>space. The dialog to change this is not entirely intuitive; you have to click the [...] button next to the current binding.

For the record, Xubuntu 14.04 and ibus 1.5.5-1ubuntu3

Revision history for this message
Neal McBurnett (nealmcb) wrote :

Re: #20 - it looks like it is upstream that changed to super+space, not Debian:
 https://github.com/ibus/ibus/releases

1.5.3: Release 1.5.3 Takao Fujiwara fujiwarat released this on Jul 26, 2013.... This version changes the default hotkey from Control + space to Super + space. You can customize the hotkey with ibus-setup.

The code changes (to more than just the xml file, Jorge) are here:

Defalut triggers key is changed to <Super>space. · f3d80dc · ibus/ibus
 https://github.com/ibus/ibus/commit/f3d80dc026853c1024cdf6bda31b1496939cb095

So Ubuntu is overriding upstream! Why?

Aha - it is patched back to ctrl-space in patches/ibus-xx-ctrl-space.patch as a "transitional solution in trusty" because of this bug in gnome-settings-daemon I guess:

Bug #1249208 “Avoid conflicting <Super>Space shortcut with g-s-d...” : Bugs : “ibus” package : Ubuntu
 https://bugs.launchpad.net/ubuntu/+source/ibus/+bug/1249208

Trusty LTS is not a release to be doing transitional solutions in....

This bug among other things has caused me to lose data in emacs, because set-mark-command doesn't work from ctrl-space like it has for what, decades? And my fingers expect it to continue to work that way. I set the mark and delete the region as a muscle macro. Very dangerous.

This needs to work right for all the desktops, rather than breaking it for everything except one desktop.

Revision history for this message
era (era) wrote :
Changed in emacs24 (Debian):
status: Unknown → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.