]> git.eshelyaron.com Git - emacs.git/commitdiff
Improve display of compositions by "C-u C-x ="
authorEli Zaretskii <eliz@gnu.org>
Thu, 9 Jul 2020 17:42:04 +0000 (20:42 +0300)
committerEli Zaretskii <eliz@gnu.org>
Thu, 9 Jul 2020 17:42:04 +0000 (20:42 +0300)
* lisp/descr-text.el (describe-char): On TTY frames, display the
Unicode names of the composed characters as well.  (Bug#42256)

lisp/descr-text.el

index 776ce7618d55a7f6eb249bc17aca130d344faea9..22c162a05ac019d3bbde69a0da40c8bdfc45d313 100644 (file)
@@ -763,6 +763,8 @@ The character information includes:
                        (to (nth 4 composition))
                        glyph)
                   (if (fontp font)
+                      ;; GUI frame: show composition in terms of font
+                      ;; glyphs.
                       (progn
                         (insert " using this font:\n  "
                                 (symbol-name (font-get font :type))
@@ -773,11 +775,14 @@ The character information includes:
                                     (setq glyph (lgstring-glyph gstring from)))
                           (insert (format "  %S\n" glyph))
                           (setq from (1+ from))))
+                    ;; TTY frame: show composition in terms of characters.
                     (insert " by these characters:\n")
                     (while (and (<= from to)
                                 (setq glyph (lgstring-glyph gstring from)))
-                      (insert (format " %c (#x%x)\n"
-                                      (lglyph-char glyph) (lglyph-char glyph)))
+                      (insert (format " %c (#x%x) %s\n"
+                                      (lglyph-char glyph) (lglyph-char glyph)
+                                      (get-char-code-property
+                                       (lglyph-char glyph) 'name)))
                       (setq from (1+ from)))))
               (insert " by the rule:\n\t(")
               (let ((first t))