 (cond ((and IS-MAC (fboundp 'mac-auto-operator-composition-mode))
        (mac-auto-operator-composition-mode))
       ;; Harfbuzz builds do not need font-specific ligature support
-      ;; if they brought in the fe903c5 commit
+      ;; if they are above emacs-27
       ((and (version<= "28.0" emacs-version)
             (string-match-p "HARFBUZZ" system-configuration-features)
             (not (null +prog-ligatures-modes)))

when matched.

Because of the underlying code in :ui pretty-code module, the regex should match a string
starting with the character contained in car."
  )

;; Defaults to not org-mode because org-bullets might be incompatible
;; with the ?*-based replacements in the default value of +prg-ligatures-alist
(defvar +prog-ligatures-modes '(not org-mode)
  "List of major modes in which ligatures should be enabled.

If t, enable it everywhere.

If the first element is 'not, enable it in any mode besides what is listed.

If nil, fallback to the prettify-symbols based replacement (add +font features to pretty-code)."
  )

(defun +pretty-code-init-ligatures-h ()
  "Enable ligatures.


(add-hook 'after-change-major-mode-hook #'+pretty-code-init-pretty-symbols-h)

;;; Automatic font-specific ligatures
(defvar +prog-ligatures-alist
  '((?! . "!\\(?:\\(==\\|[!=]\\)[!=]?\\)")
    (?# . "#\\(?:\\(###?\\|_(\\|[(:=?[_{]\\)[#(:=?[_{]?\\)")
