Configured for a Mac-like experience
Apple Magic Keyboard 2: Model A1644 (same as MLA22LL/A ?)
Mapping for Linux Mint 18 Cinnamon 64-bit
Go to System Settings > Keyboard > Layouts > English (US) > Options... > Ctrl key position > check:
* Swap Left Win key with Left Ctrl key
* Swap Right Win key with Right Ctrl key
There are a lot of different variations for the modifier keys in these settings. This is just my preference and what I thought worked best for me.
$ xmodmap -pke
You can run
$ xev
for an interactive experience by pressing each key and seeing the response. This is more detailed but much longer, as you have to press each key to get the keycode.
110 Home => 67 F1
115 End => 68 F2
112 Prior => 73 F7
118 Insert => 74 F8
117 Next => 75 F9
119 Delete => 169 Eject
A personal preference of mine is to use this new mapping, but also keep the original keys by allowing it through the use of:
Shift+Key
for example, Shift+F1
, will output F1
, but just F1
will output Home
...
$ xmodmap -e "keycode 67 = Home F1"
$ xmodmap -e "keycode 68 = End F2"
$ xmodmap -e "keycode 73 = Prior F7"
$ xmodmap -e "keycode 74 = Insert F8"
$ xmodmap -e "keycode 75 = Next F9"
$ xmodmap -e "keycode 169 = Delete"
I have no use for an eject key, thus I will not keep for use with Shift
Your custom keys should work immdiately.
Note your changes in case you have to revert your custom mapping.
For example, reverse Home back to F1:
$ xmodmap -e "keycode 110 = Home"
$ xmodmap -e "keycode 67 = F1"
or revert each custom key:
$ xmodmap ~/xmodmap_original
$ xmodmap -pke > ~/.Xmodmap
$ xmodmap ~/.Xmodmap
If you find your custom key mapping is reverting after you login or reboot, then load it up for each session:
Create a new file called '.xinitrc' in your home directory and copy this in it:
if [ -s ~/.Xmodmap ]; then
xmodmap ~/.Xmodmap
fi
thanks to http://xahlee.info/linux/linux_xmodmap_tutorial.html for the build on boot tip.
Go to System Settings > Keyboard > Shortcuts > General >
Toggle Scale > F3
Toggle Expo > F4