In Manjaro Fluxbox there is no keyboard layout switch in the panel/toolbar tray.
How do I add that?
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It only takes a minute to sign up.Sign up to join this community
ibus in the software manager:
Start with command
It should already appear in the systemtray.
Right-click the tray icon to access preferences, set a switch shortcut key and add layouts.
Add this line to
Switch the layouts by left clicking the tray icon or by using the shortcut to see list of choices.
This solution seems to have a serious limitation in that it may lack access to some layout variants.
The question is about the toolbar.
The below solution is a workaround for Wbar, a launcher which cannot use any keyboard applets.
This worked for me in Manjaro Fluxbar 15.09, which had Wbar installed by default.
Pending a definitive answer, as a workaround for Manjaro Fluxbox one may consider the Wbar dock as an alternative way to access each layout as a launcher.
This is a light dock with fewer options than even the lightest out there like Plank and Docky. It is installed by default in Manjaro-Fluxbox 15.09.
It is meant as a simple application launcher (although it can also show open windows icons as a taskbar if needed).
It can be edited to launch whatever command and then assign a name and an icon to be shown in the Wbar.
The commands to be used for each keyboard layout are discussed here.
The general form is (e.g. French):
For icons, search the internet for "flag icons" or "letter icons"; alternatively, customized icons can be created. For example, below I have used a png file easily created by screenshot-cropping a grey wallpaper; on the grey image, the letters were written with Shutter).
Or, with void icons by just adding letters in Shutter:
They are enlarged when focused with the mouse:
In the images above, I removed the 'iconbar' and replaced it with the Wbar as indicated here.
Maybe even more convenient is to switch keyboard layouts through a launcher like Synapse by creating layout-specific desktop-file launchers.
More on that, here.
Synapse is not depending on any panel, toolbar or dock, but in a similar way keyboard layout selection will work in any panel launcher like Unity Dash, Xfce WhiskerMenu, KDE launchers (Kickoff, Homerun, Lancelot etc), etc.
I tried ibus, but had 2 problems with that:
- could not set the keyboard variant (at least in its GUI)
- did not support switching keyboard layouts with just
Shift (it wants also a "real key" in addition to that)
Based on https://bbs.archlinux.org/viewtopic.php?id=212804 I had success with gxkb (I did not try the other *xkb mentioned as the OP was happy with gxkb). Some reading of gxkb man page revealed that while it is running you can use setxkbmap to configure it. It works fine on Openbox + Tint2 panel. In my openbox autostart file I added:
gxkb & # just to make sure sleep 1 setxkbmap us,hu ,102_qwerty_dot_dead -option grp:alt_shift_toggle