Skip to content

Instantly share code, notes, and snippets.

@klang
Created August 20, 2010 07:03
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save klang/539783 to your computer and use it in GitHub Desktop.
Save klang/539783 to your computer and use it in GitHub Desktop.
Luddite mode for emacs gives a few extra lines, when the tool-, menu- and scroll-bars are turned off.
;; first, remove all the crap that looks different from emacs 20.7.1
; luddite mode
(cond ((> emacs-major-version 20)
(tool-bar-mode -1) ; introduced in emacs 21
(menu-bar-mode -1)
(scroll-bar-mode -1)
(menu-bar-showhide-fringe-menu-customize-disable)
(blink-cursor-mode -1)
(windmove-default-keybindings 'meta)))
; toggles luddite mode
(global-set-key [f12] '(lambda () (interactive) (menu-bar-mode nil) (scroll-bar-mode nil)))
(defun toggle-mode-line () "toggles the modeline on and off"
(interactive)
(setq mode-line-format
(if (equal mode-line-format nil)
(default-value 'mode-line-format)) )
(redraw-display))
(global-set-key [M-f12] 'toggle-mode-line)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment