Add ligature support

Disabled prof perf'ing
This commit is contained in:
2022-12-05 10:52:48 -05:00
parent 4adf6fac65
commit 5c311b83d4

34
init.el
View File

@@ -53,6 +53,37 @@
;; Ensure use-package.el is installed ;; Ensure use-package.el is installed
(straight-use-package 'use-package) (straight-use-package 'use-package)
;; Load font ligatures, fancy arrows etc.
(use-package ligature
:straight (ligature
:package "ligature"
:host github
:type git
:repo "mickeynp/ligature.el")
:config
;; Enable the "www" ligature in every possible major mode
(ligature-set-ligatures 't '("www"))
;; Enable traditional ligature support in eww-mode, if the
;; `variable-pitch' face supports it
(ligature-set-ligatures 'eww-mode '("ff" "fi" "ffi"))
;; Enable all Cascadia Code ligatures in programming modes
(ligature-set-ligatures 'prog-mode '("|||>" "<|||" "<==>" "<!--" "####" "~~>" "***" "||=" "||>"
":::" "::=" "=:=" "===" "==>" "=!=" "=>>" "=<<" "=/=" "!=="
"!!." ">=>" ">>=" ">>>" ">>-" ">->" "->>" "-->" "---" "-<<"
"<~~" "<~>" "<*>" "<||" "<|>" "<$>" "<==" "<=>" "<=<" "<->"
"<--" "<-<" "<<=" "<<-" "<<<" "<+>" "</>" "###" "#_(" "..<"
"..." "+++" "/==" "///" "_|_" "www" "&&" "^=" "~~" "~@" "~="
"~>" "~-" "**" "*>" "*/" "||" "|}" "|]" "|=" "|>" "|-" "{|"
"[|" "]#" "::" ":=" ":>" ":<" "$>" "==" "=>" "!=" "!!" ">:"
">=" ">>" ">-" "-~" "-|" "->" "--" "-<" "<~" "<*" "<|" "<:"
"<$" "<=" "<>" "<-" "<<" "<+" "</" "#{" "#[" "#:" "#=" "#!"
"##" "#(" "#?" "#_" "%%" ".=" ".-" ".." ".?" "+>" "++" "?:"
"?=" "?." "??" ";;" "/*" "/=" "/>" "//" "__" "~~" "(*" "*)"
"\\\\" "://"))
;; Enables ligature checks globally in all buffers. You can also do it
;; per mode with `ligature-mode'.
(global-ligature-mode t))
;; Ensure shell variables are loaded ;; Ensure shell variables are loaded
(use-package exec-path-from-shell :demand (use-package exec-path-from-shell :demand
:init :init
@@ -60,8 +91,7 @@
) )
;; Profiling ;; Profiling
;; (use-package esup)
(use-package esup)
;; Prevents emacs and packages from messily writing to dirs ;; Prevents emacs and packages from messily writing to dirs
(use-package no-littering (use-package no-littering