Looks like with the update to GTK3 this key combination is reserved for the OS. More info: https://unix.stackexchange.com/questions/394655/ctrlshifte-causes-beeping/394767#394767
This will be fixed in the upcoming 3.24 release.
https://gitlab.gnome.org/GNOME/gtk/commit/8be12a2427927cf914c6223c6a2e1267352c40da
@ykgmfq I assume this means users will have to update to this version and there is no other workaround?
As far as I know, yes. It won't take long for most distributions to ship the new GTK3 release. Bundling a newer libgtk3 built from source with the snap package might be a solution for Ubuntu LTS users.
Closing as upstream, nothing more for us to action. Thanks @ykgmfq!
Workaround for people using traditional (deb|rpm) packages and stuck with older GTK versions:
If your distro uses ibus as the default input method (fedora, I believe?), you just have to open ibus-setup, go to the "emoji" tab and disable the Ctrl-Shift-e keybinding.
If your distro doesn't use ibus by default (ubuntu, AFAICT), you can either install, enable it globally and use the workaround above, or you can start vscode with env GTK_IM_MODULE=ibus (or copy the .desktop file in the package to ~/.local/share/applications and change the Exec line to include that variable)
FYI: the ibus package provides ibus-setup on Debian/Ubuntu-based distros. This is not installed by default in KDE Neon (although the shortcut is hijacked nonetheless)
Edit: Editing ibus didn't do it for me. Better fix (for me) was to use GTK_IM_MODULE="xim"
Just heads up, I used the workaround by @costela on Manjaro KDE (i.e. Arch) by installing ibus and it worked. In ibus's settings I could rebind the Ctrl+Shift+E to something else.
Make sure to restart VS Code after you change the keybinding.
In Fedora 28 using ibus-setup and deleting the short-cut seems to do nothing. Has anyone found any solutions that don't involve system wide changes?
I am happy to get rid of all emoji related input being over 9 years old :)
@David-Else if I'm not wrong, Fedora 28 uses GNOME correct? ibus should work properly with it. At least that's what Arch Wiki says: https://wiki.archlinux.org/index.php/IBus#Initial_setup
When you use Ctrl+Shift+E when ibus is enabled, do you get some sort of popup box for emojis? That's how you know if ibus is actually running.
Did you also try to set the correct environment variables like GTK_IM_MODULE? The Arch Wiki guide has more info.
I ran Fedora 28 on a VM and I got ibus to work on VS Code by setting environment variable GTK_IM_MODULE=ibus. So when I disable Ctrl+Shift+E in ibus, I regain the use of it in VS Code.
You can try it out by running: GTK_IM_MODULE=ibus code in your terminal.
@OnlyLys Fedora can run pretty much any DE, not just Gnome. Using ibus with Code (as mentioned in my post above) does not seem to fix the problem in KDE (and possibly XFCE? Just guessing since it's not GTK3-based).
@David-Else As I mentioned above, try using "xim" instead of "ibus" (just need to modify VSCode's .desktop file or test it by launching from a terminal)
Ref post: https://github.com/Microsoft/vscode/issues/48480#issuecomment-413793736
@OnlyLys @m-thorsen I managed to get it to work with a lot of messing about! I followed the steps once and it did not work, so I did it again and then it worked?! This is a super annoying bug.
What worked was to delete the shortcut in ibus-setup then start vs code with:
GTK_IM_MODULE=ibus code
I tried to edit the desktop file but it just stopped appearing, what exact line should I have in there? Cheers. I guess I need to create a special alias for code on the command line to launch code with the added GTK_IM_MODULE=ibuscode in front unless there is a better way? Thanks guys!
@David-Else David, what you're setting with GTK_IM_MODULE=ibus is an environment variable. You're setting the GTK_IM_MODULE variable to ibus. In my opinion, you should have it set globally so when you just call the plain code in the terminal, the environment variable will already have the correct value. Furthermore, this will cause all GTK programs to use ibus as well (there's also a QT_IM_MODULE=ibus variable that you can set that will cause Qt programs to use ibus).
There are a few ways you can set an environmental variable globally but it depends on what Distro / Desktop Environment you're running. Typically you would hear advice to edit a ~/.profile or ~/.bash_profile file or something like that, but your best bet is to Google search the instructions for your distro, because each distro may do things differently and it can get confusing fast.
For instance, my distro uses KDE and KDE have provided a really simple way to add environment variables just by adding a script file to my configurations folder. My script file basically contains three things:
export GTK_IM_MODULE=ibus
export XMODIFIERS=@im=ibus
export QT_IM_MODULE=ibus
Note that you might also have to add ibus-daemon -d to your startup programs so you don't have to start the background service every time you log into your desktop environment.
@OnlyLys Thanks for the info! Yesterday I added:
alias code="GTK_IM_MODULE=ibus code"
to my .bashrc in Fedora 28 and it seems to work great.
Can you see a downside to doing it this way? ibus is loaded by default, there are no other steps involved.
@David-Else what is the complete list of things that you've changed? I've disabled the shortcut in ibus-setup, added the alias and even rebooted and it still doesn't help. Not even when starting code from terminal. I've also tried exporting the variable and changing the desktop file. I'm using default F28 with Gnome.
It is bizarre how this this not considered an issue.
@GeorgeSapkin I just did it on another Fedora 28 machine successfully.
GTK_IM_MODULE=ibus code into the terminal. This should work!This will only work when using the command line, you need to mod the desktop file to sort it from that angle.
It worked first time here in that order, but I do remember it acted funny on the last machine and I had to do it twice... or something like that. I forget.
You are right, this is a massive issues, and it should at least be mentioned in the readme for the release.
Most helpful comment
FYI: the
ibuspackage providesibus-setupon Debian/Ubuntu-based distros. This is not installed by default in KDE Neon (although the shortcut is hijacked nonetheless)Edit: Editing ibus didn't do it for me. Better fix (for me) was to use
GTK_IM_MODULE="xim"