mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-24 06:20:43 -08:00
Fix minor text quoting in calc, calendar, vc
* lisp/calc/calc-ext.el (calc-shift-Z-prefix-help): * lisp/calc/calc-help.el (calc-j-prefix-help): * lisp/calc/calc-misc.el (calc-help): * lisp/calc/calc.el (calc-algebraic-mode, calc-mode): Escape an apostrophe in a docstring. * lisp/calc/calc-forms.el (calc-hms-notation): * lisp/calc/calc-mode.el (calc-display-raw, calc-algebraic-mode): Escape an apostrophe in a diagnostic. * lisp/calc/calc-misc.el (calc-help): * lisp/calendar/diary-lib.el (diary-include-files): * lisp/calendar/todo-mode.el (todo-prefix, todo-item-mark): * lisp/vc/diff-mode.el (diff-delete-trailing-whitespace): * lisp/vc/ediff-diff.el (ediff-same-contents): * lisp/vc/ediff-merg.el (ediff-re-merge): * lisp/vc/ediff-ptch.el (ediff-patch-file-internal): * lisp/vc/ediff-util.el (ediff-test-save-region) (ediff-status-info): * lisp/vc/ediff.el (ediff-merge-revisions) (ediff-merge-revisions-with-ancestor): * lisp/vc/pcvs.el (cvs-mode-checkout, cvs-vc-command-advice): * lisp/vc/vc-cvs.el (vc-cvs-mode-line-string): Respect text quoting style in doc string or diagnostic. * lisp/calc/calc-prog.el (calc-kbd-push, calc-kbd-pop): * lisp/vc/add-log.el (change-log-goto-source): Avoid double-formatting. * lisp/vc/ediff-init.el (format-message): New backward-compatibility alias.
This commit is contained in:
parent
ff441d3508
commit
5e63c84200
19 changed files with 94 additions and 84 deletions
|
|
@ -1988,7 +1988,7 @@ calc-kill calc-kill-region calc-yank))))
|
|||
"kbd-macros: [ (if), : (else), | (else-if), ] (end-if)"
|
||||
"kbd-macros: < > (repeat), ( ) (for), { } (loop)"
|
||||
"kbd-macros: / (break)"
|
||||
"kbd-macros: \\=` (save), ' (restore)")
|
||||
"kbd-macros: \\=` (save), \\=' (restore)")
|
||||
"user" ?Z))
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@
|
|||
|
||||
|
||||
(defun calc-hms-notation (fmt)
|
||||
(interactive "sHours-minutes-seconds format (hms, @ ' \", etc.): ")
|
||||
(interactive "sHours-minutes-seconds format (hms, @ \\=' \", etc.): ")
|
||||
(calc-wrapper
|
||||
(if (string-match "\\`\\([^,; ]+\\)\\([,; ]*\\)\\([^,; ]\\)\\([,; ]*\\)\\([^,; ]\\)\\'" fmt)
|
||||
(progn
|
||||
|
|
|
|||
|
|
@ -546,7 +546,7 @@ C-w Describe how there is no warranty for Calc."
|
|||
'("Select, Additional, Once; eVal, Formula; Rewrite"
|
||||
"More, Less, 1-9, Next, Previous"
|
||||
"Unselect, Clear; Display; Enable; Breakable"
|
||||
"' (replace), \\=` (edit), +, -, *, /, RET (grab), DEL"
|
||||
"\\=' (replace), \\=` (edit), +, -, *, /, RET (grab), DEL"
|
||||
"SHIFT + swap: Left, Right; maybe: Select, Once"
|
||||
"SHIFT + Commute, Merge, Distrib, jump-Eqn, Isolate"
|
||||
"SHIFT + Negate, & (invert); Unpack")
|
||||
|
|
|
|||
|
|
@ -225,7 +225,7 @@ Calc user interface as before (either C-x * C or C-x * K; initially C-x * C).
|
|||
"Letter keys: SHIFT + Num-eval; More-recn; eXec-kbd-macro; Keep-args"
|
||||
"Other keys: +, -, *, /, ^, \\ (int div), : (frac div)"
|
||||
"Other keys: & (1/x), | (concat), % (modulo), ! (factorial)"
|
||||
"Other keys: ' (alg-entry), = (eval), \\=` (edit); M-RET (last-args)"
|
||||
"Other keys: \\=' (alg-entry), = (eval), \\=` (edit); M-RET (last-args)"
|
||||
"Other keys: SPC/RET (enter/dup), LFD (over); < > (scroll horiz)"
|
||||
"Other keys: DEL (drop), M-DEL (drop-above); { } (scroll vert)"
|
||||
"Other keys: TAB (swap/roll-dn), M-TAB (roll-up)"
|
||||
|
|
@ -253,11 +253,12 @@ Calc user interface as before (either C-x * C or C-x * K; initially C-x * C).
|
|||
0))
|
||||
(let ((msg (nth calc-help-phase msgs)))
|
||||
(message "%s" (if msg
|
||||
(concat msg ":"
|
||||
(concat (substitute-command-keys msg) ":"
|
||||
(make-string (- (apply 'max
|
||||
(mapcar 'length
|
||||
msgs))
|
||||
(length msg)) 32)
|
||||
(length msg))
|
||||
?\ )
|
||||
" [?=MORE]")
|
||||
""))))))))
|
||||
|
||||
|
|
|
|||
|
|
@ -258,7 +258,7 @@
|
|||
(setq calc-display-raw (if calc-display-raw nil (if arg 0 t)))
|
||||
(calc-do-refresh)
|
||||
(if calc-display-raw
|
||||
(message "Press d ' again to cancel \"raw\" display mode"))))
|
||||
(message "%s" "Press d ' again to cancel \"raw\" display mode"))))
|
||||
|
||||
|
||||
|
||||
|
|
@ -446,7 +446,7 @@
|
|||
(calc-change-mode '(calc-algebraic-mode calc-incomplete-algebraic-mode)
|
||||
(list (not calc-algebraic-mode) nil)))
|
||||
(use-local-map calc-mode-map)
|
||||
(message (if calc-algebraic-mode
|
||||
(message "%s" (if calc-algebraic-mode
|
||||
"Numeric keys and ( and [ begin algebraic entry"
|
||||
(if calc-incomplete-algebraic-mode
|
||||
"Only ( and [ begin algebraic entry"
|
||||
|
|
|
|||
|
|
@ -1441,7 +1441,7 @@ Redefine the corresponding command."
|
|||
(let ((calc-kbd-push-level 0))
|
||||
(execute-kbd-macro (substring body 0 -2))))
|
||||
(let ((calc-kbd-push-level (1+ calc-kbd-push-level)))
|
||||
(message "Saving modes; type Z' to restore")
|
||||
(message "%s" "Saving modes; type Z' to restore")
|
||||
(recursive-edit))))))
|
||||
|
||||
(defun calc-kbd-pop ()
|
||||
|
|
@ -1450,7 +1450,7 @@ Redefine the corresponding command."
|
|||
(progn
|
||||
(message "Mode settings restored")
|
||||
(exit-recursive-edit))
|
||||
(error "Unbalanced Z' in keyboard macro")))
|
||||
(error "%s" "Unbalanced Z' in keyboard macro")))
|
||||
|
||||
|
||||
;; (defun calc-kbd-report (msg)
|
||||
|
|
|
|||
|
|
@ -736,7 +736,7 @@ If hms, angles are in degrees-minutes-seconds.")
|
|||
|
||||
(defcalcmodevar calc-algebraic-mode nil
|
||||
"If non-nil, numeric entry accepts whole algebraic expressions.
|
||||
If nil, algebraic expressions must be preceded by \"'\".")
|
||||
If nil, algebraic expressions must be preceded by \"\\='\".")
|
||||
|
||||
(defcalcmodevar calc-incomplete-algebraic-mode nil
|
||||
"Like calc-algebraic-mode except only affects ( and [ keys.")
|
||||
|
|
@ -1311,7 +1311,7 @@ This is an RPN calculator featuring arbitrary-precision integer, rational,
|
|||
floating-point, complex, matrix, and symbolic arithmetic.
|
||||
|
||||
RPN calculation: 2 RET 3 + produces 5.
|
||||
Algebraic style: ' 2+3 RET produces 5.
|
||||
Algebraic style: \\=' 2+3 RET produces 5.
|
||||
|
||||
Basic operators are +, -, *, /, ^, & (reciprocal), % (modulo), n (change-sign).
|
||||
|
||||
|
|
@ -1330,7 +1330,7 @@ Notations: 3.14e6 3.14 * 10^6
|
|||
[1 .. 4) semi-open interval, 1 <= x < 4
|
||||
2 +/- 3 (p key) number with mean 2, standard deviation 3
|
||||
2 mod 3 (M key) number 2 computed modulo 3
|
||||
<1 jan 91> Date form (enter using ' key)
|
||||
<1 jan 91> Date form (enter using \\=' key)
|
||||
|
||||
|
||||
\\{calc-mode-map}
|
||||
|
|
|
|||
|
|
@ -910,10 +910,12 @@ This is recursive; that is, included files may include other files."
|
|||
(diary-list-entries original-date number t)))))
|
||||
(display-warning
|
||||
:error
|
||||
(format "Can't read included diary file %s\n" diary-file)))
|
||||
(format-message "Can't read included diary file %s\n"
|
||||
diary-file)))
|
||||
(display-warning
|
||||
:error
|
||||
(format "Can't find included diary file %s\n" diary-file)))))
|
||||
(format-message "Can't find included diary file %s\n"
|
||||
diary-file)))))
|
||||
(goto-char (point-min)))
|
||||
|
||||
(defun diary-include-other-diary-files ()
|
||||
|
|
|
|||
|
|
@ -237,7 +237,8 @@ The final element is \"*\", indicating an unspecified month.")
|
|||
(when (string= (widget-value widget) todo-item-mark)
|
||||
(widget-put
|
||||
widget :error
|
||||
"Invalid value: must be distinct from ‘todo-item-mark’")
|
||||
(format-message
|
||||
"Invalid value: must be distinct from ‘todo-item-mark’"))
|
||||
widget)))
|
||||
:initialize 'custom-initialize-default
|
||||
:set 'todo-reset-prefix
|
||||
|
|
@ -1694,7 +1695,8 @@ only when no items are marked."
|
|||
(when (string= (widget-value widget) todo-prefix)
|
||||
(widget-put
|
||||
widget :error
|
||||
"Invalid value: must be distinct from ‘todo-prefix’")
|
||||
(format-message
|
||||
"Invalid value: must be distinct from ‘todo-prefix’"))
|
||||
widget)))
|
||||
:set (lambda (symbol value)
|
||||
(custom-set-default symbol (propertize value 'face 'todo-mark)))
|
||||
|
|
|
|||
|
|
@ -481,9 +481,9 @@ try to visit the file for the change under `point' instead."
|
|||
(apply 'change-log-goto-source-1
|
||||
(append change-log-find-head change-log-find-tail))
|
||||
(error
|
||||
(format "Cannot find more matches for tag `%s' in file `%s'"
|
||||
"Cannot find more matches for tag `%s' in file `%s'"
|
||||
(car change-log-find-head)
|
||||
(nth 2 change-log-find-head)))))
|
||||
(nth 2 change-log-find-head))))
|
||||
(save-excursion
|
||||
(let* ((at (point))
|
||||
(tag-at (change-log-search-tag-name))
|
||||
|
|
@ -515,9 +515,8 @@ try to visit the file for the change under `point' instead."
|
|||
(condition-case nil
|
||||
(setq change-log-find-tail
|
||||
(apply 'change-log-goto-source-1 change-log-find-head))
|
||||
(error
|
||||
(format "Cannot find matches for tag `%s' in file `%s'"
|
||||
tag file)))))))))
|
||||
(error "Cannot find matches for tag `%s' in file `%s'"
|
||||
tag file))))))))
|
||||
|
||||
(defun change-log-next-error (&optional argp reset)
|
||||
"Move to the Nth (default 1) next match in a ChangeLog buffer.
|
||||
|
|
|
|||
|
|
@ -2128,7 +2128,8 @@ fixed, visit it in a buffer."
|
|||
(goto-char hunk-end))
|
||||
(if modified-buffers
|
||||
(message "Deleted trailing whitespace from %s."
|
||||
(mapconcat (lambda (buf) (concat "`" (buffer-name buf) "'"))
|
||||
(mapconcat (lambda (buf) (format-message
|
||||
"`%s'" (buffer-name buf)))
|
||||
modified-buffers ", "))
|
||||
(message "No trailing whitespace to delete.")))))
|
||||
|
||||
|
|
|
|||
|
|
@ -1373,7 +1373,7 @@ affects only files whose names match the expression."
|
|||
;; Normalize empty filter RE to nil.
|
||||
(unless (> (length filter-re) 0) (setq filter-re nil))
|
||||
;; Indicate progress
|
||||
(message "Comparing ‘%s’ and ‘%s’ modulo ‘%s’" d1 d2 filter-re)
|
||||
(message "Comparing `%s' and `%s' modulo `%s'" d1 d2 filter-re)
|
||||
(cond
|
||||
;; D1 & D2 directories => recurse
|
||||
((and (file-directory-p d1)
|
||||
|
|
|
|||
|
|
@ -1719,6 +1719,9 @@ Unless optional argument INPLACE is non-nil, return a new string."
|
|||
(aset newstr i tochar)))
|
||||
newstr)))
|
||||
|
||||
(unless (fboundp 'format-message)
|
||||
(defalias 'format-message 'format))
|
||||
|
||||
(defun ediff-abbrev-jobname (jobname)
|
||||
(cond ((eq jobname 'ediff-directories)
|
||||
"Compare two directories")
|
||||
|
|
|
|||
|
|
@ -268,7 +268,7 @@ Buffer B."
|
|||
(setq ediff-default-variant
|
||||
(intern
|
||||
(completing-read
|
||||
(format "Current merge default is `%S'. New default: "
|
||||
(format-message "Current merge default is `%S'. New default: "
|
||||
ediff-default-variant)
|
||||
actual-alist nil 'must-match)))
|
||||
(ediff-do-merge ediff-current-difference 'remerge)
|
||||
|
|
|
|||
|
|
@ -723,7 +723,7 @@ optional argument, then use it."
|
|||
(with-output-to-temp-buffer ediff-msg-buffer
|
||||
(ediff-with-current-buffer standard-output
|
||||
(fundamental-mode))
|
||||
(princ (format
|
||||
(princ (format-message
|
||||
"Patch program has failed due to a bad patch file,
|
||||
it couldn't apply all hunks, OR
|
||||
it couldn't create the backup for the file being patched.
|
||||
|
|
|
|||
|
|
@ -2097,7 +2097,7 @@ ARG is a prefix argument. If nil, copy the current difference region."
|
|||
|
||||
(if this-buf-n-th-diff-saved
|
||||
(if (yes-or-no-p
|
||||
(format
|
||||
(format-message
|
||||
"You've previously copied diff region %d to buffer %S. Confirm? "
|
||||
(1+ n) buf-type))
|
||||
t
|
||||
|
|
@ -2858,13 +2858,14 @@ Hit \\[ediff-recenter] to reset the windows afterward."
|
|||
(B-line (ediff-with-current-buffer ediff-buffer-B
|
||||
(1+ (count-lines (point-min) (point)))))
|
||||
C-line)
|
||||
(princ (format "\Buffer A's point is on line %d\n" A-line))
|
||||
(princ (format "Buffer B's point is on line %d\n" B-line))
|
||||
(princ (format-message "Buffer A's point is on line %d\n" A-line))
|
||||
(princ (format-message "Buffer B's point is on line %d\n" B-line))
|
||||
(if ediff-3way-job
|
||||
(progn
|
||||
(setq C-line (ediff-with-current-buffer ediff-buffer-C
|
||||
(1+ (count-lines (point-min) (point)))))
|
||||
(princ (format "Buffer C's point is on line %d\n" C-line)))))
|
||||
(princ (format-message
|
||||
"Buffer C's point is on line %d\n" C-line)))))
|
||||
|
||||
(princ (format "\nCurrent difference number = %S\n"
|
||||
(cond ((< ediff-current-difference 0) 'start)
|
||||
|
|
@ -2890,7 +2891,7 @@ Hit \\[ediff-recenter] to reset the windows afterward."
|
|||
(princ
|
||||
"\nIgnoring regions that match")
|
||||
(princ
|
||||
(format
|
||||
(format-message
|
||||
"\n\t regexp `%s' in buffer A %S\n\t regexp `%s' in buffer B\n"
|
||||
ediff-regexp-hide-A ediff-hide-regexp-connective
|
||||
ediff-regexp-hide-B)))
|
||||
|
|
@ -2899,14 +2900,15 @@ Hit \\[ediff-recenter] to reset the windows afterward."
|
|||
(princ
|
||||
"\nFocusing on regions that match")
|
||||
(princ
|
||||
(format
|
||||
(format-message
|
||||
"\n\t regexp `%s' in buffer A %S\n\t regexp `%s' in buffer B\n"
|
||||
ediff-regexp-focus-A ediff-focus-regexp-connective
|
||||
ediff-regexp-focus-B)))
|
||||
(t (princ "\nSelective browsing via a user-defined method.\n")))
|
||||
|
||||
(princ
|
||||
(format "\nBugs/suggestions: type `%s' while in Ediff Control Panel."
|
||||
(format-message
|
||||
"\nBugs/suggestions: type `%s' while in Ediff Control Panel."
|
||||
(substitute-command-keys "\\[ediff-submit-report]")))
|
||||
) ; with output
|
||||
(if (frame-live-p ediff-control-frame)
|
||||
|
|
|
|||
|
|
@ -1294,7 +1294,7 @@ buffer."
|
|||
(let (rev1 rev2)
|
||||
(setq rev1
|
||||
(read-string
|
||||
(format
|
||||
(format-message
|
||||
"Version 1 to merge (default %s's working version): "
|
||||
(if (stringp file)
|
||||
(file-name-nondirectory file) "current buffer")))
|
||||
|
|
@ -1326,7 +1326,7 @@ buffer."
|
|||
(let (rev1 rev2 ancestor-rev)
|
||||
(setq rev1
|
||||
(read-string
|
||||
(format
|
||||
(format-message
|
||||
"Version 1 to merge (default %s's working version): "
|
||||
(if (stringp file)
|
||||
(file-name-nondirectory file) "current buffer")))
|
||||
|
|
@ -1338,7 +1338,7 @@ buffer."
|
|||
(file-name-nondirectory file) "current buffer")))
|
||||
ancestor-rev
|
||||
(read-string
|
||||
(format
|
||||
(format-message
|
||||
"Ancestor version (default %s's base revision): "
|
||||
(if (stringp file)
|
||||
(file-name-nondirectory file) "current buffer"))))
|
||||
|
|
|
|||
|
|
@ -968,7 +968,7 @@ With a prefix argument, prompt for cvs FLAGS to use."
|
|||
The files are stored to DIR."
|
||||
(interactive
|
||||
(let* ((branch (cvs-prefix-get 'cvs-branch-prefix))
|
||||
(prompt (format "CVS Checkout Directory for `%s%s': "
|
||||
(prompt (format-message "CVS Checkout Directory for `%s%s': "
|
||||
(cvs-get-module)
|
||||
(if branch (format " (branch: %s)" branch)
|
||||
""))))
|
||||
|
|
@ -2403,9 +2403,9 @@ The exact behavior is determined also by `cvs-dired-use-hook'."
|
|||
(goto-char (point-min))
|
||||
(looking-at ".*to add this file permanently\n\\'"))
|
||||
(dolist (file (if (listp files) files (list files)))
|
||||
(insert "cvs add: scheduling file `"
|
||||
(file-name-nondirectory file)
|
||||
"' for addition\n")))
|
||||
(insert (format-message
|
||||
"cvs add: scheduling file `%s' for addition\n"
|
||||
(file-name-nondirectory file)))))
|
||||
;; VC never (?) does `cvs -n update' so dcd=nil
|
||||
;; should probably always be the right choice.
|
||||
(cvs-parse-process nil subdir))))))))
|
||||
|
|
|
|||
|
|
@ -281,7 +281,7 @@ committed and support display of sticky tags."
|
|||
(propertize
|
||||
(if (zerop (length sticky-tag))
|
||||
string
|
||||
(setq help-echo (format-message "%s on the ‘%s’ branch"
|
||||
(setq help-echo (format-message "%s on the `%s' branch"
|
||||
help-echo sticky-tag))
|
||||
(concat string "[" sticky-tag "]"))
|
||||
'help-echo help-echo)))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue