3

I am using ibus-avro on Ubuntu 20.04. I have 2 input sources: en, bn. I am using F8 to switch the sources. When switching, a large prompt-like thing (I don't know the exact term) is shown on screen. I cannot take a screenshot of it (Print Screen is not working while it is visible), but it looks something like this:

prompt-like thing looks like this

It is annoying, and it also seems to prevent typing for a moment until it goes away. How to hide this and just switch the input source instantly? Thanks.

UPDATE: This issue does not seem that annoying when using Ctrl+Space or Super+Space for switching input sources. In those cases, it only seems to be visible as long as the Ctrl or Super (respectively) key is held down.

CluelessNoob
  • 2,383

1 Answers1

0

Workaround Only

You can create an executable script with below content and bind the script to F8 Key

#!/bin/bash

totalLang=$(gdbus call --session --dest org.gnome.Shell --object-path /org/gnome/Shell --method org.gnome.Shell.Eval "imports.ui.status.keyboard.getInputSourceManager()._mruSources.length" | grep -oP "(?<=').*?(?=')")

currentLang=$(gdbus call --session --dest org.gnome.Shell --object-path /org/gnome/Shell --method org.gnome.Shell.Eval "imports.ui.status.keyboard.getInputSourceManager().currentSource.index" | grep -oP "(?<=').*?(?=')")

math=$((currentLang+1))

if [ "$math" -lt "$totalLang" ]; then
gdbus call --session --dest org.gnome.Shell --object-path /org/gnome/Shell --method org.gnome.Shell.Eval "imports.ui.status.keyboard.getInputSourceManager().inputSources["$currentLang+1"].activate()"
else
gdbus call --session --dest org.gnome.Shell --object-path /org/gnome/Shell --method org.gnome.Shell.Eval "imports.ui.status.keyboard.getInputSourceManager().inputSources[0].activate()"
fi
muru
  • 207,228