Revert "Prefer ‘format’ to ‘substitute-command-keys’"
This reverts commit 6af5aad264
.
This commit is contained in:
parent
70ff62413a
commit
0b0c9565d0
13 changed files with 97 additions and 71 deletions
|
@ -752,16 +752,16 @@ including `cl-block' and `cl-eval-when'."
|
|||
;; FIXME: Add a `cl-class-of' or `cl-typeof' or somesuch.
|
||||
(metatype (cl--class-name (symbol-value (aref class 0)))))
|
||||
(insert (symbol-name type)
|
||||
(format " is a type (of kind ‘"))
|
||||
(substitute-command-keys " is a type (of kind ‘"))
|
||||
(help-insert-xref-button (symbol-name metatype)
|
||||
'cl-help-type metatype)
|
||||
(insert (format "’)"))
|
||||
(insert (substitute-command-keys "’)"))
|
||||
(when location
|
||||
(insert (format " in ‘"))
|
||||
(insert (substitute-command-keys " in ‘"))
|
||||
(help-insert-xref-button
|
||||
(help-fns-short-filename location)
|
||||
'cl-type-definition type location 'define-type)
|
||||
(insert (format "’")))
|
||||
(insert (substitute-command-keys "’")))
|
||||
(insert ".\n")
|
||||
|
||||
;; Parents.
|
||||
|
@ -771,10 +771,10 @@ including `cl-block' and `cl-eval-when'."
|
|||
(insert " Inherits from ")
|
||||
(while (setq cur (pop pl))
|
||||
(setq cur (cl--class-name cur))
|
||||
(insert (format "‘"))
|
||||
(insert (substitute-command-keys "‘"))
|
||||
(help-insert-xref-button (symbol-name cur)
|
||||
'cl-help-type cur)
|
||||
(insert (format (if pl "’, " "’"))))
|
||||
(insert (substitute-command-keys (if pl "’, " "’"))))
|
||||
(insert ".\n")))
|
||||
|
||||
;; Children, if available. ¡For EIEIO!
|
||||
|
@ -785,10 +785,10 @@ including `cl-block' and `cl-eval-when'."
|
|||
(when ch
|
||||
(insert " Children ")
|
||||
(while (setq cur (pop ch))
|
||||
(insert (format "‘"))
|
||||
(insert (substitute-command-keys "‘"))
|
||||
(help-insert-xref-button (symbol-name cur)
|
||||
'cl-help-type cur)
|
||||
(insert (format (if ch "’, " "’"))))
|
||||
(insert (substitute-command-keys (if ch "’, " "’"))))
|
||||
(insert ".\n")))
|
||||
|
||||
;; Type's documentation.
|
||||
|
@ -804,10 +804,10 @@ including `cl-block' and `cl-eval-when'."
|
|||
(when generics
|
||||
(insert (propertize "Specialized Methods:\n\n" 'face 'bold))
|
||||
(dolist (generic generics)
|
||||
(insert (format "‘"))
|
||||
(insert (substitute-command-keys "‘"))
|
||||
(help-insert-xref-button (symbol-name generic)
|
||||
'help-function generic)
|
||||
(insert (format "’"))
|
||||
(insert (substitute-command-keys "’"))
|
||||
(pcase-dolist (`(,qualifiers ,args ,doc)
|
||||
(cl--generic-method-documentation generic type))
|
||||
(insert (format " %s%S\n" qualifiers args)
|
||||
|
|
|
@ -864,11 +864,11 @@ MET-NAME is a cons (SYMBOL . SPECIALIZERS)."
|
|||
(cl--generic-method-specializers method)))
|
||||
(file (find-lisp-object-file-name met-name 'cl-defmethod)))
|
||||
(when file
|
||||
(insert (format " in ‘"))
|
||||
(insert (substitute-command-keys " in ‘"))
|
||||
(help-insert-xref-button (help-fns-short-filename file)
|
||||
'help-function-def met-name file
|
||||
'cl-defmethod)
|
||||
(insert (format "’.\n"))))
|
||||
(insert (substitute-command-keys "’.\n"))))
|
||||
(insert "\n" (or (nth 2 info) "Undocumented") "\n\n")))))))
|
||||
|
||||
(defun cl--generic-specializers-apply-to-type-p (specializers type)
|
||||
|
|
|
@ -141,11 +141,11 @@ are not abstract."
|
|||
(setq location
|
||||
(find-lisp-object-file-name ctr def)))
|
||||
(when location
|
||||
(insert (format " in ‘"))
|
||||
(insert (substitute-command-keys " in ‘"))
|
||||
(help-insert-xref-button
|
||||
(help-fns-short-filename location)
|
||||
'cl-type-definition ctr location 'define-type)
|
||||
(insert (format "’")))
|
||||
(insert (substitute-command-keys "’")))
|
||||
(insert ".\nCreates an object of class " (symbol-name ctr) ".")
|
||||
(goto-char (point-max))
|
||||
(if (autoloadp def)
|
||||
|
|
|
@ -2204,7 +2204,7 @@ Otherwise no newline is inserted."
|
|||
"Installed"
|
||||
(capitalize status))
|
||||
'font-lock-face 'package-status-builtin-face))
|
||||
(insert (format " in ‘"))
|
||||
(insert (substitute-command-keys " in ‘"))
|
||||
(let ((dir (abbreviate-file-name
|
||||
(file-name-as-directory
|
||||
(if (file-in-directory-p pkg-dir package-user-dir)
|
||||
|
@ -2213,10 +2213,11 @@ Otherwise no newline is inserted."
|
|||
(help-insert-xref-button dir 'help-package-def pkg-dir))
|
||||
(if (and (package-built-in-p name)
|
||||
(not (package-built-in-p name version)))
|
||||
(insert (format "’,\n shadowing a ")
|
||||
(insert (substitute-command-keys
|
||||
"’,\n shadowing a ")
|
||||
(propertize "built-in package"
|
||||
'font-lock-face 'package-status-builtin-face))
|
||||
(insert (format "’")))
|
||||
(insert (substitute-command-keys "’")))
|
||||
(if signed
|
||||
(insert ".")
|
||||
(insert " (unsigned)."))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue