summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2015-08-28 20:32:03 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2015-08-28 20:32:39 -0700
commitff441d3508add9eed3c5217ae7b0a8800b9fc917 (patch)
tree7cb511c46c115ef734e563d29ebf058e54838a70
parentc6af816affb36d512f806725518e6e5f2353b197 (diff)
downloademacs-ff441d3508add9eed3c5217ae7b0a8800b9fc917.tar.gz
Fix minor text quoting problems in lisp top level
* lisp/apropos.el (apropos-describe-plist): * lisp/cus-theme.el (customize-themes): * lisp/dired.el (dired-log): * lisp/help-fns.el (describe-variable): * lisp/hexl.el (hexl-insert-multibyte-char): * lisp/info.el (Info-finder-find-node): * lisp/json.el (json-read-string): * lisp/novice.el (disabled-command-function) (disabled-command-function): * lisp/startup.el (normal-mouse-startup-screen): * lisp/woman.el (WoMan-log, WoMan-warn): Respect text quoting style in doc string or diagnostic. * lisp/replace.el (replace-character-fold): * src/syntax.c (Fmodify_syntax_entry): Escape an apostrophe in a docstring. * lisp/tempo.el (tempo-define-template): Remove confusing apostrophe from docstring. * lisp/whitespace.el (whitespace-mark-x): Use directed quotes in docstring.
-rw-r--r--lisp/apropos.el2
-rw-r--r--lisp/cus-theme.el2
-rw-r--r--lisp/dired.el2
-rw-r--r--lisp/help-fns.el17
-rw-r--r--lisp/hexl.el2
-rw-r--r--lisp/info.el2
-rw-r--r--lisp/json.el2
-rw-r--r--lisp/novice.el7
-rw-r--r--lisp/replace.el2
-rw-r--r--lisp/startup.el3
-rw-r--r--lisp/tempo.el2
-rw-r--r--lisp/whitespace.el4
-rw-r--r--lisp/woman.el4
-rw-r--r--src/syntax.c2
14 files changed, 30 insertions, 23 deletions
diff --git a/lisp/apropos.el b/lisp/apropos.el
index 73f86df11e4..ec212968db6 100644
--- a/lisp/apropos.el
+++ b/lisp/apropos.el
@@ -1205,7 +1205,7 @@ If non-nil, TEXT is a string that will be printed as a heading."
(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 "))
diff --git a/lisp/cus-theme.el b/lisp/cus-theme.el
index bc221e17c4b..7693c70aea9 100644
--- a/lisp/cus-theme.el
+++ b/lisp/cus-theme.el
@@ -587,7 +587,7 @@ Theme files are named *-theme.el in `"))
: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.
diff --git a/lisp/dired.el b/lisp/dired.el
index f47c066ee47..206de373ade 100644
--- a/lisp/dired.el
+++ b/lisp/dired.el
@@ -3567,7 +3567,7 @@ Thus, use \\[backward-page] to find the beginning of a group of errors."
(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")))))))
diff --git a/lisp/help-fns.el b/lisp/help-fns.el
index 5f0dc87bc04..a1d121c457f 100644
--- a/lisp/help-fns.el
+++ b/lisp/help-fns.el
@@ -746,7 +746,7 @@ it is displayed along with the global value."
(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))
@@ -859,11 +859,14 @@ it is displayed along with the global value."
((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)
@@ -896,7 +899,8 @@ if it is given a local binding.\n")))
(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 ")
@@ -918,7 +922,8 @@ if it is given a local binding.\n")))
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)
diff --git a/lisp/hexl.el b/lisp/hexl.el
index 3e0ea410620..4aa76d23cb7 100644
--- a/lisp/hexl.el
+++ b/lisp/hexl.el
@@ -935,7 +935,7 @@ and their encoded form is inserted byte by byte."
(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)
diff --git a/lisp/info.el b/lisp/info.el
index 21dbca9ee58..2c92df4ec16 100644
--- a/lisp/info.el
+++ b/lisp/info.el
@@ -3763,7 +3763,7 @@ Build a menu of the possible matches."
;; 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)
diff --git a/lisp/json.el b/lisp/json.el
index eaf8596a6dc..5392a13f9e0 100644
--- a/lisp/json.el
+++ b/lisp/json.el
@@ -286,7 +286,7 @@ representation will be parsed correctly."
(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 '())
diff --git a/lisp/novice.el b/lisp/novice.el
index ce6e16f1117..18ffa5da0e5 100644
--- a/lisp/novice.el
+++ b/lisp/novice.el
@@ -65,7 +65,8 @@ If nil, the feature is disabled, i.e., all commands work normally.")
(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))
@@ -80,11 +81,11 @@ If nil, the feature is disabled, i.e., all commands work normally.")
(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))
diff --git a/lisp/replace.el b/lisp/replace.el
index 26870a3a634..be73cab8d2a 100644
--- a/lisp/replace.el
+++ b/lisp/replace.el
@@ -35,7 +35,7 @@
(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
diff --git a/lisp/startup.el b/lisp/startup.el
index 1cb3bb6d8aa..8c63ed263c2 100644
--- a/lisp/startup.el
+++ b/lisp/startup.el
@@ -1935,7 +1935,8 @@ To quit a partially entered command, type Control-g.\n")
(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)
diff --git a/lisp/tempo.el b/lisp/tempo.el
index 92e1ea78da4..6e2f978b5b7 100644
--- a/lisp/tempo.el
+++ b/lisp/tempo.el
@@ -270,7 +270,7 @@ The elements in ELEMENTS can be of several types:
- 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-"
diff --git a/lisp/whitespace.el b/lisp/whitespace.el
index ddc37f10180..319149638d6 100644
--- a/lisp/whitespace.el
+++ b/lisp/whitespace.el
@@ -1931,13 +1931,13 @@ cleaning up these problems."
(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)
diff --git a/lisp/woman.el b/lisp/woman.el
index e903caaea30..de2cbc100ea 100644
--- a/lisp/woman.el
+++ b/lisp/woman.el
@@ -4548,11 +4548,11 @@ Format paragraphs upto TO."
(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.
diff --git a/src/syntax.c b/src/syntax.c
index 30560affdf0..dc82210e79d 100644
--- a/src/syntax.c
+++ b/src/syntax.c
@@ -1129,7 +1129,7 @@ The first character of NEWENTRY should be one of the following:
_ 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.