Created
October 13, 2011 00:49
-
-
Save nriley/1283061 to your computer and use it in GitHub Desktop.
This file contains 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
(defun toggle-frame-fullscreen (&optional frame) | |
(interactive) | |
(set-frame-parameter frame 'fullscreen | |
(if (null (frame-parameter frame 'fullscreen)) | |
'fullboth nil))) | |
(global-set-key "\C-x59" 'toggle-frame-fullscreen) | |
; ediff-toggle-wide-display tries to use the entire display width, | |
; which breaks with multiple monitors | |
(defun ediff-fullscreen-as-wide-display () | |
(if (eq window-system 'mac) | |
(defadvice ediff-toggle-wide-display | |
(around ediff-toggle-frame-fullscreen activate) | |
(toggle-frame-fullscreen (window-frame ediff-window-A)) | |
(raise-frame ediff-control-frame)))) | |
(add-hook 'ediff-mode-hook 'ediff-fullscreen-as-wide-display) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment