From: Stefan Bund Date: Fri, 13 Oct 2017 11:00:01 +0000 (+0200) Subject: better C-x = (safe-maximize-window) binding X-Git-Url: http://g0dil.de/git?a=commitdiff_plain;h=a3cc80e69cdad940bd67c706e40f7f749291496a;p=emacs-init.git better C-x = (safe-maximize-window) binding --- diff --git a/setup/mywin.el b/setup/mywin.el index b33e6a5..4fde816 100644 --- a/setup/mywin.el +++ b/setup/mywin.el @@ -215,5 +215,10 @@ the buffer stack in the current window." (error "Current window is not a top window")) (shrink-window-horizontally (- (- width (window-width) (* window-min-width (1- count))))))) -(global-set-key "\C-x=" 'safe-max-window-horizontally) +(defun safe-max-window () + (interactive) + (safe-max-window-horizontally) + (maximize-window 5)) + +(global-set-key "\C-x=" 'safe-max-window) (global-set-key "\C-x-" 'maximize-window-15)