Created
June 6, 2016 17:39
-
-
Save slackorama/cdc0cfa622ab9507f8e4c0318c938c70 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(help/on-osx | |
(setq mac-control-modifier 'control) | |
(setq mac-right-control-modifier 'left) | |
(setq mac-command-modifier 'meta) | |
(setq mac-right-command-modifier 'left) | |
(setq mac-option-modifier 'super) | |
(setq mac-right-option-modifier 'left) | |
(setq mac-function-modifier 'hyper) | |
(defun help/toggle-mac-right-option-modifier () | |
"Toggle between passing option modifier either to Emacs or OS X." | |
(interactive) | |
(let ((old-ropt mac-right-option-modifier)) | |
(setq mac-right-option-modifier | |
(if (eq mac-right-option-modifier 'left) | |
'none | |
'left)) | |
(message "Toggled `mac-right-option-modifier' from %s to %s." | |
old-ropt | |
mac-right-option-modifier))) | |
(defun help/toggle-mac-function-modifier () | |
"Toggle between passing function modifier either to Emacs or OS X." | |
(interactive) | |
(let ((old-func mac-function-modifier)) | |
(setq mac-function-modifier | |
(if (eq mac-function-modifier 'hyper) | |
'none | |
'hyper)) | |
(message "Toggled `mac-function-modifier' from %s to %s." | |
old-func | |
mac-function-modifier)))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment