summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Voss <mail@thomasvoss.com> 2024-09-08 22:41:42 +0200
committerThomas Voss <mail@thomasvoss.com> 2024-09-08 22:41:42 +0200
commitd21529788a6f591965441d062672f871aacd8711 (patch)
treebd5c3c91afd636d5e3c0c96b246a926f2a4db410
parent80d4dd2d359a99a4728f494ed483aee0d4c9532b (diff)
emacs: Support ligatures
-rw-r--r--.config/emacs/init.el14
1 files changed, 14 insertions, 0 deletions
diff --git a/.config/emacs/init.el b/.config/emacs/init.el
index 5fd6f06..aad1603 100644
--- a/.config/emacs/init.el
+++ b/.config/emacs/init.el
@@ -631,6 +631,20 @@ font name, font weight, and font height in that order.")
(add-hook 'after-make-frame-functions (lambda (_) (x-set-fonts)))
(x-set-fonts))
+;; Setup ligatures
+(use-package ligature
+ :config
+ (ligature-set-ligatures
+ 'c-mode
+ '("->" "<=" ">=" "==" "!=" "*=" "__"))
+ (ligature-set-ligatures
+ 'go-ts-mode
+ '("<=" ">=" "==" "!=" "*=" ":="))
+ (ligature-set-ligatures
+ 'html-mode
+ '("<!--" "-->" "/>"))
+ (global-ligature-mode))
+
;;; Set Project List
(defun x-set-project-list ()
(interactive)