emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/tuareg b403403aa7 01/10: Generalize the prettify-symbols t


From: ELPA Syncer
Subject: [nongnu] elpa/tuareg b403403aa7 01/10: Generalize the prettify-symbols to accept UTF-8 combining sequences
Date: Tue, 27 Sep 2022 06:59:16 -0400 (EDT)

branch: elpa/tuareg
commit b403403aa705900154babd9d63c3523a81cf1bc4
Author: Christophe Troestler <Christophe.Troestler@umons.ac.be>
Commit: Christophe Troestler <Christophe.Troestler@umons.ac.be>

    Generalize the prettify-symbols to accept UTF-8 combining sequences
---
 tuareg.el | 17 ++++++++++++++++-
 1 file changed, 16 insertions(+), 1 deletion(-)

diff --git a/tuareg.el b/tuareg.el
index be2a0c8d13..bdff1c97e2 100644
--- a/tuareg.el
+++ b/tuareg.el
@@ -533,6 +533,7 @@ do not perturb in essential ways the alignment are used.  
See
 
 (defvar tuareg-prettify-symbols-basic-alist
   `(("sqrt" . ?√)
+    ("cbrt" . ?∛)
     ("&&" . ?∧)        ; 'LOGICAL AND' (U+2227)
     ("||" . ?∨)        ; 'LOGICAL OR' (U+2228)
     ("+." . ?∔)        ;DOT PLUS (U+2214)
@@ -540,6 +541,18 @@ do not perturb in essential ways the alignment are used.  
See
     ;;("*." . ?×)
     ("*." . ?∙)   ; BULLET OPERATOR
     ("/." . ?÷)
+    ("+:" . "̈+"); (⨥ + ➕ ⨁ ⨢)
+    ("-:" . "̈-"); COMBINING DIAERESIS ̈-  (⨪ - ➖)
+    ("*:" .  "̈∙"); (⨱ * ✕ ✖ ⁑ ◦ ⨰ ⦿ ⨀ ⨂)
+    ("/:" . "̈÷"); (➗)
+    ("+^" . ?⨣)
+    ("-^" . "̂-") ; COMBINING CIRCUMFLEX ACCENT
+    ("*^" . "̂∙")
+    ("/^" . "̂÷")
+    ("+~" . ?⨤)
+    ("-~" . "̃-") ; COMBINING TILDE
+    ("*~" . "̃∙")
+    ("/~" . "̃÷")
     ("<-" . ?←)
     ("<=" . ?≤)
     (">=" . ?≥)
@@ -618,7 +631,9 @@ Regexp match data 0 points to the chars."
                            tuareg-prettify-symbols-extra-alist)
                  tuareg-prettify-symbols-basic-alist)))
     (dolist (x alist)
-      (when (and (char-displayable-p (cdr x))
+      (when (and (or (and (number-or-marker-p (cdr x))
+                          (char-displayable-p (cdr x)))
+                     (seq-every-p #'char-displayable-p (cdr x)))
                  (not (assoc (car x) alist))) ; not yet in alist.
         (push x alist)))
     (when alist



reply via email to

[Prev in Thread] Current Thread [Next in Thread]