(set-buffer standard-output)
(princ "Symbol ")
(prin1 symbol)
- (princ "'s plist is\n (")
+ (princ (substitute-command-keys "'s plist is\n ("))
(put-text-property (+ (point-min) 7) (- (point) 14)
'face 'apropos-symbol)
(insert (apropos-format-plist symbol "\n "))
:follow-link 'mouse-face
:action (lambda (_widget &rest _ignore)
(describe-variable 'custom-theme-load-path)))
- (widget-insert "'.\n\n")
+ (widget-insert (substitute-command-keys "'.\n\n"))
;; If the user has made customizations, display a warning and
;; provide buttons to disable or convert them.
(unless (bolp)
(insert "\n"))
(insert (current-time-string)
- "\tBuffer `" (buffer-name obuf) "'\n")
+ (format-message "\tBuffer ‘%s’\n" (buffer-name obuf)))
(goto-char (point-max))
(insert "\f\n")))))))
(princ "Its ")))
(if valvoid
(princ " is void as a variable.")
- (princ "'s "))))
+ (princ (substitute-command-keys "’s ")))))
(unless valvoid
(with-current-buffer standard-output
(setq val-start-pos (point))
((not permanent-local))
((bufferp locus)
(setq extra-line t)
- (princ " This variable's buffer-local value is permanent.\n"))
+ (princ
+ (substitute-command-keys
+ " This variable's buffer-local value is permanent.\n")))
(t
(setq extra-line t)
- (princ " This variable's value is permanent \
-if it is given a local binding.\n")))
+ (princ (substitute-command-keys
+ " This variable's value is permanent \
+if it is given a local binding.\n"))))
;; Mention if it's an alias.
(unless (eq alias variable)
(dir-locals-find-file
(buffer-file-name buffer))))
(dir-file t))
- (princ " This variable's value is directory-local")
+ (princ (substitute-command-keys
+ " This variable's value is directory-local"))
(if (null file)
(princ ".\n")
(princ ", set ")
file 'type 'help-dir-local-var-def
'help-args (list variable file)))
(princ (substitute-command-keys "’.\n"))))
- (princ " This variable's value is file-local.\n")))
+ (princ (substitute-command-keys
+ " This variable's value is file-local.\n"))))
(when (memq variable ignored-local-variables)
(setq extra-line t)
(mapconcat (function (lambda (c) (format "%x" c)))
internal " "))
(if (yes-or-no-p
- (format
+ (format-message
"Insert char 0x%x's internal representation \"%s\"? "
ch internal-hex))
(setq encoded internal)
;; I think nxml is the only exception - maybe it should be just be renamed.
(let ((str (ignore-errors (lm-commentary (find-library-name nodename)))))
(if (null str)
- (insert "Can't find package description.\n\n")
+ (insert "Can’t find package description.\n\n")
(insert
(with-temp-buffer
(insert str)
(defun json-read-string ()
"Read the JSON string at point."
(unless (char-equal (json-peek) ?\")
- (signal 'json-string-format (list "doesn't start with '\"'!")))
+ (signal 'json-string-format (list "doesn’t start with ‘\"’!")))
;; Skip over the '"'
(json-advance)
(let ((characters '())
(if (stringp (get cmd 'disabled))
(princ (get cmd 'disabled))
(princ "It is disabled because new users often find it confusing.\n")
- (princ "Here's the first part of its description:\n\n")
+ (princ (substitute-command-keys
+ "Here's the first part of its description:\n\n"))
;; Keep only the first paragraph of the documentation.
(with-current-buffer "*Disabled Command*" ;; standard-output
(goto-char (point-max))
(goto-char (point-max))
(indent-rigidly start (point) 3))))
(princ "\n\nDo you want to use this command anyway?\n\n")
- (princ "You can now type
+ (princ (substitute-command-keys "You can now type
y to try it and enable it (no questions if you use it again).
n to cancel--don't try the command, and it remains disabled.
SPC to try the command just this once, but leave it disabled.
-! to try it, and enable all disabled commands for this session only.")
+! to try it, and enable all disabled commands for this session only."))
;; Redundant since with-output-to-temp-buffer will do it anyway.
;; (with-current-buffer standard-output
;; (help-mode))
(defcustom replace-character-fold nil
"Non-nil means `query-replace' should do character folding in matches.
-This means, for instance, that ' will match a large variety of
+This means, for instance, that \\=' will match a large variety of
unicode quotes."
:type 'boolean
:group 'matching
(insert-button "Visit New File"
'action (lambda (_button) (call-interactively 'find-file))
'follow-link t)
- (insert "\t\tSpecify a new file's name, to edit the file\n")
+ (insert (substitute-command-keys
+ "\t\tSpecify a new file's name, to edit the file\n"))
(insert-button "Open Home Directory"
'action (lambda (_button) (dired "~"))
'follow-link t)
- nil: It is ignored.
- Anything else: It is evaluated and the result is treated as an
element to be inserted. One additional tag is useful for these
- cases. If an expression returns a list '(l foo bar), the elements
+ cases. If an expression returns a list (l foo bar), the elements
after `l' will be inserted according to the usual rules. This makes
it possible to return several elements from one expression."
(let* ((template-name (intern (concat "tempo-template-"
(defun whitespace-mark-x (nchars condition)
- "Insert the mark ('X' or ' ') after NCHARS depending on CONDITION."
+ "Insert the mark (‘X’ or ‘ ’) after NCHARS depending on CONDITION."
(forward-char nchars)
(insert (if condition "X" " ")))
(defun whitespace-insert-option-mark (the-list the-value)
- "Insert the option mark ('X' or ' ') in toggle options buffer."
+ "Insert the option mark (‘X’ or ‘ ’) in toggle options buffer."
(goto-char (point-min))
(forward-line 2)
(dolist (sym the-list)
(defun WoMan-log (format &rest args)
"Log a message out of FORMAT control string and optional ARGS."
- (WoMan-log-1 (apply 'format format args)))
+ (WoMan-log-1 (apply #'format-message format args)))
(defun WoMan-warn (format &rest args)
"Log a warning message out of FORMAT control string and optional ARGS."
- (setq format (apply 'format format args))
+ (setq format (apply #'format-message format args))
(WoMan-log-1 (concat "** " format)))
;; request is not used dynamically by any callees.
_ symbol constituent. . punctuation.
( open-parenthesis. ) close-parenthesis.
" string quote. \\ escape.
- $ paired delimiter. ' expression quote or prefix operator.
+ $ paired delimiter. \\=' expression quote or prefix operator.
< comment starter. > comment ender.
/ character-quote. @ inherit from parent table.
| generic string fence. ! generic comment fence.