diff options
author | Alan Pearce | 2015-11-29 16:51:10 +0100 |
---|---|---|
committer | Alan Pearce | 2015-11-29 16:51:10 +0100 |
commit | 47b52b5cfbffe149fd7e73e7c47d2a07885a0273 (patch) | |
tree | 7a5b9a80b150d1a42a6e88b10774a6bc630aa73e /tag-emacs | |
parent | f6c7ab84e4b275c7f9f920e29714963783c19b7f (diff) | |
parent | b8b160a427b785514c0e016155194bcc86976d62 (diff) | |
download | dotfiles-47b52b5cfbffe149fd7e73e7c47d2a07885a0273.tar.lz dotfiles-47b52b5cfbffe149fd7e73e7c47d2a07885a0273.tar.zst dotfiles-47b52b5cfbffe149fd7e73e7c47d2a07885a0273.zip |
Merge branch 'master' of github.com:alanpearce/dotfiles
Diffstat (limited to 'tag-emacs')
-rw-r--r-- | tag-emacs/emacs.d/init.org | 54 |
1 files changed, 29 insertions, 25 deletions
diff --git a/tag-emacs/emacs.d/init.org b/tag-emacs/emacs.d/init.org index fe3fed4..777b6f9 100644 --- a/tag-emacs/emacs.d/init.org +++ b/tag-emacs/emacs.d/init.org @@ -273,29 +273,29 @@ Highlighting quasi-quoted expressions in lisps is quite useful. When possible, set up fonts. I don’t have any settings here for X11, because I manage those in my [[file:~/projects/dotfiles/tag-xresources/xresources/main][XResources file]]. #+BEGIN_SRC emacs-lisp -(when (or (display-graphic-p) - (daemonp)) - - (defun use-variable-fonts () - (interactive) - (variable-pitch-mode) - (setq cursor-type 'bar)) - - (defun ap/set-fonts (mono-face variable-face font-size) - (when mono-face - (let ((default-font (concat mono-face "-" (number-to-string font-size)))) - (add-to-list 'default-frame-alist `(font . ,default-font)) - (set-face-font 'fixed-pitch default-font) - (set-frame-font default-font t t))) - (when variable-face - (set-face-font 'variable-pitch (concat variable-face "-" - (number-to-string (1+ font-size)))))) - - (cond - ((eq window-system 'w32) - (ap/set-fonts "Consolas" "Segoe UI" 10)) - ((eq system-type 'darwin) - (ap/set-fonts "Input Mono" "Input Sans Condensed" 13)))) + (when (or (display-graphic-p) + (daemonp)) + + (defun use-variable-fonts () + (interactive) + (variable-pitch-mode) + (setq cursor-type 'bar)) + + (defun ap/set-fonts (mono-face mono-font-size variable-face variable-font-size) + (when mono-face + (let ((default-font (concat mono-face "-" (number-to-string mono-font-size)))) + (add-to-list 'default-frame-alist `(font . ,default-font)) + (set-face-font 'fixed-pitch default-font) + (set-frame-font default-font t t))) + (when variable-face + (set-face-font 'variable-pitch (concat variable-face "-" + (number-to-string variable-font-size))))) + + (cond + ((eq window-system 'w32) + (ap/set-fonts "Consolas" 10 "Segoe UI" 11)) + ((eq system-type 'darwin) + (ap/set-fonts "Hack" 14 "Avenir" 14)))) #+END_SRC Allow font-lock-mode to do background parsing. I’m not really sure if @@ -562,6 +562,7 @@ whitespace-sensitive language, of course. (add-to-list 'auto-indent-disabled-modes-list 'yaml-mode) (add-to-list 'auto-indent-disabled-modes-list 'saltstack-mode) (add-to-list 'auto-indent-disabled-modes-list 'nix-mode) + (add-to-list 'auto-indent-disabled-modes-list 'coffee-mode) (auto-indent-global-mode))) #+END_SRC @@ -1879,7 +1880,9 @@ it though #+BEGIN_SRC emacs-lisp (use-package coffee-mode - :mode ("\\.coffee\\'" . coffee-mode)) + :mode ("\\.coffee\\'" . coffee-mode) + :config (progn + (setq coffee-indent-like-python-mode t))) #+END_SRC *** tern @@ -2304,7 +2307,8 @@ nice as the real version (sp-local-pair "{{" "}}")) (show-smartparens-global-mode t) (smartparens-global-strict-mode t) - (add-hook 'lisp-mode-common-hook #'turn-off-smartparens-mode))) + (add-hook 'lisp-mode-common-hook #'turn-off-smartparens-mode) + (add-hook 'coffee-mode-hook #'turn-off-smartparens-mode))) #+END_SRC ** move-text |