dot/emacs, el/dot-emacs.el: Consistently use `setq-default' for mode defaults.
authorMark Wooding <mdw@distorted.org.uk>
Fri, 13 Sep 2019 16:20:11 +0000 (17:20 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Fri, 13 Sep 2019 16:21:29 +0000 (17:21 +0100)
More-or-less consistently anyway.

dot/emacs
el/dot-emacs.el

index ba3096b..9c6fa6b 100644 (file)
--- a/dot/emacs
+++ b/dot/emacs
   (tooltip-mode 0)
   (tool-bar-mode 0))
 (trap (or mdw-fast-startup (global-auto-revert-mode t)))
-(setq psgml-html-build-new-buffer nil)
+(setq-default psgml-html-build-new-buffer nil)
 
 (defvar mdw-black-background t)
 
 
 (add-hook 'rexx-mode-hook 'mdw-fontify-rexx t)
 
-(setq sml-nested-if-indent t
-      sml-case-indent nil
-      sml-indent-level 4
-      sml-type-of-indent nil)
+(setq-default sml-nested-if-indent t
+             sml-case-indent nil
+             sml-indent-level 4
+             sml-type-of-indent nil)
 (add-hook 'sml-mode-hook 'mdw-fontify-sml t)
 
 (add-hook 'haskell-mode-hook 'mdw-fontify-haskell t)
 (add-hook 'texinfo-mode-hook 'mdw-fontify-texinfo t)
 (add-hook 'TeXinfo-mode-hook 'mdw-fontify-texinfo t)
 
-(setq LaTeX-table-label "tbl:")
-(setq TeX-auto-untabify nil)
+(setq-default LaTeX-table-label "tbl:"
+             TeX-auto-untabify nil)
 (add-hook 'TeX-mode-hook 'mdw-fontify-tex t)
 (add-hook 'tex-mode-hook 'mdw-fontify-tex t)
 (add-hook 'LaTeX-mode-hook 'mdw-fontify-tex t)
index 92614ca..12d0e72 100644 (file)
@@ -2797,14 +2797,14 @@ name, as a symbol."
 
 ;; Perl indentation style.
 
-(setq perl-indent-level 2)
+(setq-default perl-indent-level 2)
 
-(setq cperl-indent-level 2)
-(setq cperl-continued-statement-offset 2)
-(setq cperl-continued-brace-offset 0)
-(setq cperl-brace-offset -2)
-(setq cperl-brace-imaginary-offset 0)
-(setq cperl-label-offset 0)
+(setq-default cperl-indent-level 2
+             cperl-continued-statement-offset 2
+             cperl-continued-brace-offset 0
+             cperl-brace-offset -2
+             cperl-brace-imaginary-offset 0
+             cperl-label-offset 0)
 
 ;; Define perl fontification style.
 
@@ -2927,7 +2927,7 @@ strip numbers instead."
 ;;;--------------------------------------------------------------------------
 ;;; Lua programming style.
 
-(setq lua-indent-level 2)
+(setq-default lua-indent-level 2)
 
 (defun mdw-fontify-lua ()
 
@@ -2972,10 +2972,10 @@ strip numbers instead."
 
 ;; Icon indentation style.
 
-(setq icon-brace-offset 0
-      icon-continued-brace-offset 0
-      icon-continued-statement-offset 2
-      icon-indent-level 2)
+(setq-default icon-brace-offset 0
+             icon-continued-brace-offset 0
+             icon-continued-statement-offset 2
+             icon-indent-level 2)
 
 ;; Define Icon fontification style.
 
@@ -3130,7 +3130,7 @@ strip numbers instead."
 ;;;--------------------------------------------------------------------------
 ;;; Algol 68 configuration.
 
-(setq a68-indent-step 2)
+(setq-default a68-indent-step 2)
 
 (defun mdw-fontify-algol-68 ()
 
@@ -3375,7 +3375,7 @@ strip numbers instead."
 ;;;--------------------------------------------------------------------------
 ;;; Erlang configuration.
 
-(setq erlang-electric-commands nil)
+(setq-default erlang-electric-commands nil)
 
 (defun mdw-fontify-erlang ()
 
@@ -3530,15 +3530,15 @@ strip numbers instead."
           (unless modified
             (restore-buffer-modified-p nil)))))))
 
-(setq LaTeX-syntactic-comments nil
-      LaTeX-fill-break-at-separators '(\\\[))
+(setq-default LaTeX-syntactic-comments nil
+             LaTeX-fill-break-at-separators '(\\\[))
 
 (add-hook 'bibtex-mode-hook (lambda () (setq fill-column 76)))
 
 ;;;--------------------------------------------------------------------------
 ;;; HTML, CSS, and other web foolishness.
 
-(setq css-indent-offset 2)
+(setq-default css-indent-offset 2)
 
 ;;;--------------------------------------------------------------------------
 ;;; SGML hacking.
@@ -3683,8 +3683,8 @@ that character only to be normal punctuation.")
                  (concat "~" (substring pwd (length home)))
                pwd))
            right)))
-(setq eshell-prompt-function 'mdw-eshell-prompt)
-(setq eshell-prompt-regexp "^\\[[^]>]+\\(\\]\\|>>?\\)")
+(setq-default eshell-prompt-function 'mdw-eshell-prompt)
+(setq-default eshell-prompt-regexp "^\\[[^]>]+\\(\\]\\|>>?\\)")
 
 (defun eshell/e (file) (find-file file) nil)
 (defun eshell/ee (file) (find-file-other-window file) nil)
@@ -3903,9 +3903,9 @@ that character only to be normal punctuation.")
   (make-local-variable 'lisp-indent-function)
   (setq lisp-indent-function 'common-lisp-indent-function))
 
-(setq lisp-simple-loop-indentation 2
-      lisp-loop-keyword-indentation 6
-      lisp-loop-forms-indentation 6)
+(setq-default lisp-simple-loop-indentation 2
+             lisp-loop-keyword-indentation 6
+             lisp-loop-forms-indentation 6)
 
 (defmacro mdw-advise-hyperspec-lookup (func args)
   `(defadvice ,func (around mdw-browse-w3m ,args activate compile)