Browse files

Full screen vc-annotate

  • Loading branch information...
1 parent da4c93d commit b01c997c899f22e540f0f1b42740f29e4c213418 @magnars committed Nov 15, 2012
Showing with 17 additions and 0 deletions.
  1. +17 −0 setup-magit.el
View
17 setup-magit.el
@@ -39,6 +39,23 @@
(define-key magit-status-mode-map (kbd "q") 'magit-quit-session)
+;; full screen vc-annotate
+
+(defun vc-annotate-quit ()
+ "Restores the previous window configuration and kills the vc-annotate buffer"
+ (interactive)
+ (kill-buffer)
+ (jump-to-register :vc-annotate-fullscreen))
+
+(eval-after-load "vc-annotate"
+ '(progn
+ (defadvice vc-annotate (around fullscreen activate)
+ (window-configuration-to-register :vc-annotate-fullscreen)
+ ad-do-it
+ (delete-other-windows))
+
+ (define-key vc-annotate-mode-map (kbd "q") 'vc-annotate-quit)))
+
;; ignore whitespace
(defun magit-toggle-whitespace ()

0 comments on commit b01c997

Please sign in to comment.