dotfiles/emacs/.emacs.d/init/ediff-init.org

42 lines
1 KiB
Org Mode
Raw Normal View History

2016-10-14 01:16:24 +02:00
#+TITLE: Ediff
2016-10-14 01:27:26 +02:00
#+BEGIN_SRC emacs-lisp
(require 'ediff)
#+END_SRC
2016-10-14 01:16:24 +02:00
Don't use a special frame for the ediff control buffer.
#+BEGIN_SRC emacs-lisp
(setq ediff-window-setup-function 'ediff-setup-windows-plain)
#+END_SRC
Show the different buffers next to eachother instead of underneath
eachother.
#+BEGIN_SRC emacs-lisp
(setq ediff-split-window-function 'split-window-horizontally)
#+END_SRC
Don't show whitespace changes in ediff buffers.
#+BEGIN_SRC emacs-lisp
(setq ediff-diff-options "-w")
#+END_SRC
Show ediff in a fullscreen frame.
#+BEGIN_SRC emacs-lisp
(defun oni:turn-on-fullscreen ()
(unless (memq (frame-parameter nil 'fullscreen)
'(fullscreen fullboth))
(set-frame-parameter nil 'fullscreen 'fullboth)))
(defun oni:turn-off-fullscreen ()
(when (memq (frame-parameter nil 'fullscreen)
'(fullscreen fullboth))
(set-frame-parameter nil 'fullscreen nil)))
(add-hook 'ediff-mode-hook 'oni:turn-on-fullscreen)
(add-hook 'ediff-cleanup-hook 'oni:turn-off-fullscreen)
#+END_SRC