(custom-set-variables ;; custom-set-variables was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. '(org-ellipsis "…")) (require 'whitespace) (defvar cycle-whitespace-modes-state 0 "whitespace mode states: 0 -> highlighting of stray whitespace, 72 & 80 column lines 1 -> ws highlighting and identification for tabs and spaces (», ·)") (make-variable-buffer-local 'cycle-whitespace-modes-state) (defun my-cycle-whitespace-modes (&optional state) (interactive) (if state (setq cycle-whitespace-modes-state state) (setq cycle-whitespace-modes-state (mod (1+ cycle-whitespace-modes-state) 2))) (case cycle-whitespace-modes-state (0 (whitespace-mode 0) ) (otherwise (whitespace-mode 0) (whitespace-mode 1) (whitespace-toggle-options (list 'tab-mark 'space-mark)) ))) (global-set-key [f10] 'my-cycle-whitespace-modes)