The Swerty keyboard layout is created by Johan E. Gustafsson and hosted on http://johanegustafsson.net/projects/swerty/
Swerty is released under the MIT Licence.
Since I spend a lot of time getting the right alt-gr
key to work I decided to share back my fixes.
Installation instructions: Swerty for Linux
Add the contents of se.txt to the end of the file /usr/share/X11/xkb/symbols/se
.
$ sudo bash -c 'cat se.txt >> /usr/share/X11/xkb/symbols/se'
Then look up the following section in the file /usr/share/X11/xkb/rules/evdev.xml
:
<layout>
<configItem>
<name>se</name>
<shortDescription>Swe</shortDescription>
<description>Sweden</description>
<languageList><iso639Id>swe</iso639Id></languageList>
</configItem>
<variantList>
Add the following variant block after the line :
<variant>
<configItem>
<name>swerty</name>
<description>Swerty</description>
</configItem>
</variant>
Finally, after the line ! variant
in the file /usr/share/X11/xkb/rules/evdev.lst
add the following line:
swerty se: Swerty
Now Swerty should show up as one of the alternative keyboard layouts for Swedish.
Since the US layout is still more suitable in some cases (e.g. for coding). It is nice to be able to quickly change between the US and Swerty layout using the "win+space" key combination.
This can be accomplished with
$ setxkbmap -layout 'us,se' -variant ',swerty' -option 'grp:win_space_toggle'
Tack för denna fix! Behövde det på i3
/----------------------------------------------------/
Thanks for this fix! Needed it on i3