From a8aec65dfc937c90ef1a1bb9a508c3935eedf6d8 Mon Sep 17 00:00:00 2001 From: Tom Willemse Date: Sun, 20 Apr 2014 13:34:20 +0200 Subject: Move tab width setting to init.org --- .emacs.d/init.el | 1 - .emacs.d/init.org | 22 ++++++++++++++++++++++ 2 files changed, 22 insertions(+), 1 deletion(-) (limited to '.emacs.d') diff --git a/.emacs.d/init.el b/.emacs.d/init.el index 1c02126..bbda377 100644 --- a/.emacs.d/init.el +++ b/.emacs.d/init.el @@ -910,7 +910,6 @@ from myaethon2.core.decorators import ( ;;;; Unconditional settings -(setq-default tab-width 4) (setq-default truncate-lines t) (setq custom-file "~/.emacs.d/custom.el") diff --git a/.emacs.d/init.org b/.emacs.d/init.org index 4f07cf3..43c9c89 100644 --- a/.emacs.d/init.org +++ b/.emacs.d/init.org @@ -486,6 +486,26 @@ (setq-default indent-tabs-mode nil) #+END_SRC +** Use four spaces for indentation + + I once, long ago, started out with using eight spaces for each + level of indentation. Although I think, technically, I was using + tabs. This means that even just 3 levels of indentation take up a + /huge/ amount of space that can't be used for anything else. Since I + also try to limit the length of the lines in my code, this can make + for very little code per line. + + I also tried (and enjoyed) two spaces, but after a while, looking + at bigger files, I noticed that it all becomes a blur. Two spaces + is not a big-enough visual difference to make code read nicely, in + my opinion. + + So far, I have quite enjoyed four spaces for most code[fn:4]. + + #+BEGIN_SRC emacs-lisp + (setq-default tab-width 4) + #+END_SRC + * Notes Here are some random or somewhat general notes about things you may @@ -516,3 +536,5 @@ [fn:2] https://github.com/sabof/svg-mode-line-themes [fn:3] http://stackoverflow.com/questions/22175214/automatically-switch-language-in-gnus-depending-on-recipient + +[fn:4] I still use 2 spaces for some languages, like HTML. -- cgit v1.2.3-54-g00ecf