5

From time to time I have to use characters not present in my two layouts: Latin and Cyrillic and instead of digging in Character Map I thought to add 2 additional keyboard layouts.

My issue with this approach is that most of the time I use just two layouts, and while changing to different layout (Alt+Shift) I now have to press couple of times to switch to previous layout. It's not just number of pressings, but I have to press two keys at once and track keyboard indicator which is distracting.

I tried some options presented in keyboard settings, but I think there is no option that I would like - change just between first two layouts on Alt+Shift, and if I want to use additional layout I can choose it from keyboard indicator drop-down menu.

Any ideas how this might be possible?

2 Answers 2

5
+100

my approach towards this problem would be assigning a combination of keys (via keyboard shortcuts) for either using loadkeys/setxkbmap. Although, you might want to revert back to last used layout after using 'the special one', thus you might need to write a bash script for that.

2
  • This is a much better method than my suggestion, i wasn't aware of those commands. I would use this method and assign a different keyboard shortcut to each.
    – Veazer
    Apr 20, 2012 at 10:25
  • I'm using setxkbmap with Awesome Window Manager to switch between 4 different layouts - I've mapped them to Ctrl+Shift+{1,2,3,4} and can switch to any of the layouts with just one chord. So, +1 to @shookees's answer. Apr 23, 2012 at 14:39
1

Would it be possible to use the IBus keyboard instead? IBus can have multiple layouts added, but is generally just toggled on and off using Ctrl-Space. This toggles between the system keyboard layout and the currently selected ibus keyboard, rather than rotating through everything.

To test this, I think you'd need to:

  • Removed the current extra keyboard layouts added using "Keyboard Layout" and leave only your default keyboard. Verify that the standard XKB keyboard indicator icon is gone.
  • Add the package ibus-m17n
  • Run Keyboard Input Methods to start IBus

Go to IBus icon > Preferences then select and add input methods needed.

Use Ctrl + Space to enable/disable IBus and Alt + Left Shift to change IBus keyboards. These keyboard shortcuts can be change to whatever you like, including a single key.

You might want to test in a virtual machine first.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .