]> git.eshelyaron.com Git - emacs.git/commitdiff
Show the exact C-x 8 RET invocation in describe-char.
authorIvan Shmakov <ivan@siamics.net>
Wed, 27 May 2015 22:14:57 +0000 (22:14 +0000)
committerIvan Shmakov <ivan@siamics.net>
Wed, 27 May 2015 22:14:57 +0000 (22:14 +0000)
* lisp/descr-text.el (describe-char): Show the exact C-x 8 RET
invocation instead of a template.  (Bug#20522)

lisp/descr-text.el

index d6f64c77e61f9faa744fbf00f87f8e55d9d59e63..484b8cc43adf0f7a30e863ed8e61f9b8820cf8e2 100644 (file)
@@ -618,7 +618,14 @@ relevant to POS."
                                    'help-args '(,current-input-method))
                                 "input method")
                         (list
-                         "type \"C-x 8 RET HEX-CODEPOINT\" or \"C-x 8 RET NAME\"")))))
+                          (let ((name
+                                 (or (get-char-code-property char 'name)
+                                     (get-char-code-property char 'old-name))))
+                            (if name
+                                (format
+                                 "type \"C-x 8 RET %x\" or \"C-x 8 RET %s\""
+                                 char name)
+                              (format "type \"C-x 8 RET %x\"" char))))))))
               ("buffer code"
                ,(if multibyte-p
                     (encoded-string-description