summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAlan Pearce2017-04-28 17:05:03 +0200
committerAlan Pearce2017-04-28 17:05:03 +0200
commit7d5c681af4ac7a571e2bd8ff45b020562b5b3611 (patch)
treea23e3da78ed93fdf010e9a775fb7f0951fd40939
parente2f1b8d344cd2a851663bd90db26bb1036424957 (diff)
downloadnixfiles-7d5c681af4ac7a571e2bd8ff45b020562b5b3611.tar.lz
nixfiles-7d5c681af4ac7a571e2bd8ff45b020562b5b3611.tar.zst
nixfiles-7d5c681af4ac7a571e2bd8ff45b020562b5b3611.zip
Emacs: Include line-spacing in font definition
-rw-r--r--emacs/.emacs.d/init.org8
1 files changed, 5 insertions, 3 deletions
diff --git a/emacs/.emacs.d/init.org b/emacs/.emacs.d/init.org
index e83f048b..af8b5a6c 100644
--- a/emacs/.emacs.d/init.org
+++ b/emacs/.emacs.d/init.org
@@ -239,9 +239,11 @@ because I manage those in my [[file:~/projects/dotfiles/tag-xresources/xresource
     (variable-pitch-mode)
     (setq cursor-type 'bar))
 
-  (defun ap/set-fonts (mono-face mono-font-size variable-face variable-font-size antialias)
+  (defun ap/set-fonts (mono-face mono-font-size variable-face variable-font-size antialias &optional new-line-spacing)
     (if (boundp 'ns-antialias-text)
-      (setq ns-antialias-text antialias))
+        (setq ns-antialias-text antialias))
+    (if (boundp 'new-line-spacing)
+      (setq line-spacing new-line-spacing))
     (when mono-face
       (let ((default-font (font-spec :family mono-face :size  mono-font-size)))
         (add-to-list 'default-frame-alist `(font . ,(format "%s %s" mono-face mono-font-size)))
@@ -259,7 +261,7 @@ because I manage those in my [[file:~/projects/dotfiles/tag-xresources/xresource
       (let ((displays (string-to-number (shell-command-to-string "system_profiler SPDisplaysDataType | grep \"Online: Yes\" | wc -l"))))
         (if (eq displays 1)
             (ap/set-fonts "Lekton" 20 "Lucida Grande" 16 t)
-          (ap/set-fonts "Monaco" 10 "Lucida Grande" 12 nil))))
+          (ap/set-fonts "Monaco" 10 "Lucida Grande" 12 nil 0.1))))
      ((eq window-system 'x)
       (set-fontset-font "fontset-default" 'unicode (font-spec :name "Terminus" :size 14))
       (ap/set-fonts "Fixed" 14 "Lucida" 14 nil))))