Skip to content

Instantly share code, notes, and snippets.

@kylebrandt
Created February 24, 2017 23:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kylebrandt/8403f9784c4e0c0ae1cb4eea50c79cf6 to your computer and use it in GitHub Desktop.
Save kylebrandt/8403f9784c4e0c0ae1cb4eea50c79cf6 to your computer and use it in GitHub Desktop.
keyboard remappings with xkb
partial modifier_keys
xkb_symbols "kycracra" {
modifier_map Mod3 { Super_L, Super_R };
key <SUPR> { [ NoSymbol, Super_L ] };
modifier_map Mod3 { <SUPR> };
key <HYPR> { [ NoSymbol, Hyper_L ] };
modifier_map Mod4 { <HYPR> };
replace key <CAPS> {
[ VoidSymbol, VoidSymbol ]
};
modifier_map Mod4 { <CAPS> };
key <AC01> { [ a, A, colon ] };
key <AC02> { [ s, S, underscore ] };
key <AC03> { [ d, D, minus ] };
key <AC04> { [ f, F, equal ] };
key <AB01> { [ z, Z, ampersand ] };
key <AB02> { [ x, X, asterisk ] };
key <AD07> { [ u, U, braceleft ] };
key <AD08> { [ i, I, braceright ] };
key <AC07> { [ j, J, parenleft ] };
key <AC08> { [ k, K, parenright ] };
key <AB07> { [ m, M, bracketleft ] };
key <AB08> { [ comma, less, bracketright ] };
};
~
!setxkbmap -option "lv3:lwin_switch,lv3:switch" -print | sed -e '/xkb_symbols/s/"[[:space:]:]/+local&/'
| xkbcomp -I${HOME}/.xkb - $DISPLAY
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment