This repository has been archived on 2024-10-22. You can view files and clone it, but cannot push or open issues or pull requests.
spacemacs/layers/+fonts/unicode-fonts/packages.el

38 lines
1.2 KiB
EmacsLisp
Raw Normal View History

2017-08-27 15:37:56 +00:00
;;; packages.el --- unicode-fonts layer packages file for Spacemacs.
;;
2020-09-16 21:34:40 +00:00
;; Copyright (c) 2012-2020 Sylvain Benner & Contributors
2017-08-27 15:37:56 +00:00
;;
;; Author: Aaron Jensen <aaronjensen@gmail.com>
;; URL: https://github.com/syl20bnr/spacemacs
;;
;; This file is not part of GNU Emacs.
;;
;;; License: GPLv3
(defconst unicode-fonts-packages
'(unicode-fonts
persistent-soft
(ligature :location (recipe
:fetcher github
:repo "mickeynp/ligature.el")
:toggle (and (> emacs-major-version 26) unicode-fonts-enable-ligatures))))
2017-08-27 15:37:56 +00:00
(defun unicode-fonts/init-persistent-soft ()
(use-package persistent-soft
:defer t))
2017-08-27 15:37:56 +00:00
(defun unicode-fonts/init-unicode-fonts ()
(use-package unicode-fonts
:init
(progn
(when (and unicode-fonts-force-multi-color-on-mac
(eq window-system 'ns))
(setq unicode-fonts-skip-font-groups '(decorative low-quality-glyphs)))
(unicode-fonts-setup))))
(defun unicode-fonts/init-ligature ()
"Initialise the ligatures for emacs 27+"
(dolist (mode unicode-fonts-ligature-modes)
(ligature-set-ligatures mode unicode-fonts-ligature-set))
(global-ligature-mode t))