Ubuntu 16.04 and 18.04: The included script (lockscreen_lang_switcher.sh
) switches the keyboard layout to the first layout (or the specified layout)
when the system is unlocked.
- Place script in "/usr/local/bin/", make it executable (might require sudo)
sudo chmod +x lockscreen_lang_switcher.sh
- Search "Startup Applications" on your Ubuntu machine
- Click add new
- Give it a "name" and "comment"
- Set command field: "nohup /usr/local/bin/lockscreen_lang_switcher.sh -l [layout_number] &"
- Restart, switch language to other than the specified layout, press CMD + L
- Try logging in
Enjoy it!
It is possible to try running this script with other Ubuntu versions, by over-riding the version that will be set with the -r
flag.
You can either set 18.04 or 16.04. It has not been tested on other versions (and there is no intention to do so).
ps ax | grep "[l]ockscreen_lang_switcher.sh" | grep -v grep | awk '{print $2}' | xargs kill