mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2025-01-06 11:55:48 +00:00
Documentation fixes re quotes
Prefer curved quotes in examples if users will typically see curved quotes when the examples run. Mention format-message when appropriate. Don’t use @code in examples. Quote an apostrophe with @kbd.
This commit is contained in:
parent
4c24b9e30f
commit
b533552292
@ -3862,10 +3862,10 @@ tiger!} will be printed; otherwise, @code{nil} will be returned.
|
||||
@group
|
||||
(defun type-of-animal (characteristic)
|
||||
"Print message in echo area depending on CHARACTERISTIC.
|
||||
If the CHARACTERISTIC is the symbol `fierce',
|
||||
If the CHARACTERISTIC is the symbol ‘fierce’,
|
||||
then warn of a tiger."
|
||||
(if (equal characteristic 'fierce)
|
||||
(message "It's a tiger!")))
|
||||
(message "It’s a tiger!")))
|
||||
@end group
|
||||
@end smallexample
|
||||
|
||||
@ -3887,7 +3887,7 @@ can evaluate the following two expressions to see the results:
|
||||
@c Following sentences rewritten to prevent overfull hbox.
|
||||
@noindent
|
||||
When you evaluate @code{(type-of-animal 'fierce)}, you will see the
|
||||
following message printed in the echo area: @code{"It's a tiger!"}; and
|
||||
following message printed in the echo area: @code{"It’s a tiger!"}; and
|
||||
when you evaluate @code{(type-of-animal 'zebra)} you will see @code{nil}
|
||||
printed in the echo area.
|
||||
|
||||
@ -3918,7 +3918,7 @@ The parts of the function that match this template look like this:
|
||||
@group
|
||||
(defun type-of-animal (characteristic)
|
||||
"Print message in echo area depending on CHARACTERISTIC.
|
||||
If the CHARACTERISTIC is the symbol `fierce',
|
||||
If the CHARACTERISTIC is the symbol ‘fierce’,
|
||||
then warn of a tiger."
|
||||
@var{body: the} @code{if} @var{expression})
|
||||
@end group
|
||||
@ -3948,7 +3948,7 @@ looks like this:
|
||||
@smallexample
|
||||
@group
|
||||
(if (equal characteristic 'fierce)
|
||||
(message "It's a tiger!")))
|
||||
(message "It’s a tiger!")))
|
||||
@end group
|
||||
@end smallexample
|
||||
|
||||
@ -3971,7 +3971,7 @@ In the first exercise of @code{type-of-animal}, the argument
|
||||
is equal to @code{fierce}, the expression, @code{(equal characteristic
|
||||
'fierce)}, returns a value of true. When this happens, the @code{if}
|
||||
evaluates the second argument or then-part of the @code{if}:
|
||||
@code{(message "It's tiger!")}.
|
||||
@code{(message "It’s a tiger!")}.
|
||||
|
||||
On the other hand, in the second exercise of @code{type-of-animal}, the
|
||||
argument @code{zebra} is passed to @code{type-of-animal}. @code{zebra}
|
||||
@ -4034,12 +4034,11 @@ arguments to the function.
|
||||
@group
|
||||
(defun type-of-animal (characteristic) ; @r{Second version.}
|
||||
"Print message in echo area depending on CHARACTERISTIC.
|
||||
If the CHARACTERISTIC is the symbol `fierce',
|
||||
then warn of a tiger;
|
||||
else say it's not fierce."
|
||||
If the CHARACTERISTIC is the symbol ‘fierce’,
|
||||
then warn of a tiger; else say it’s not fierce."
|
||||
(if (equal characteristic 'fierce)
|
||||
(message "It's a tiger!")
|
||||
(message "It's not fierce!")))
|
||||
(message "It’s a tiger!")
|
||||
(message "It’s not fierce!")))
|
||||
@end group
|
||||
@end smallexample
|
||||
@sp 1
|
||||
@ -4056,12 +4055,12 @@ else say it's not fierce."
|
||||
@c Following sentence rewritten to prevent overfull hbox.
|
||||
@noindent
|
||||
When you evaluate @code{(type-of-animal 'fierce)}, you will see the
|
||||
following message printed in the echo area: @code{"It's a tiger!"}; but
|
||||
following message printed in the echo area: @code{"It’s a tiger!"}; but
|
||||
when you evaluate @code{(type-of-animal 'zebra)}, you will see
|
||||
@code{"It's not fierce!"}.
|
||||
@code{"It’s not fierce!"}.
|
||||
|
||||
(Of course, if the @var{characteristic} were @code{ferocious}, the
|
||||
message @code{"It's not fierce!"} would be printed; and it would be
|
||||
message @code{"It’s not fierce!"} would be printed; and it would be
|
||||
misleading! When you write code, you need to take into account the
|
||||
possibility that some such argument will be tested by the @code{if}
|
||||
and write your program accordingly.)
|
||||
@ -6349,7 +6348,7 @@ With arg N, put point N/10 of the way
|
||||
from the true beginning.
|
||||
@end group
|
||||
@group
|
||||
Don't use this in Lisp programs!
|
||||
Don’t use this in Lisp programs!
|
||||
\(goto-char (point-min)) is faster
|
||||
and does not set the mark."
|
||||
(interactive "P")
|
||||
@ -7605,8 +7604,8 @@ Here is the complete text of the version 22 implementation of the function:
|
||||
@smallexample
|
||||
@group
|
||||
(defun zap-to-char (arg char)
|
||||
"Kill up to and including ARG'th occurrence of CHAR.
|
||||
Case is ignored if `case-fold-search' is non-nil in the current buffer.
|
||||
"Kill up to and including ARG’th occurrence of CHAR.
|
||||
Case is ignored if ‘case-fold-search’ is non-nil in the current buffer.
|
||||
Goes backward if ARG is negative; error if CHAR not found."
|
||||
(interactive "p\ncZap to char: ")
|
||||
(if (char-table-p translation-table-for-input)
|
||||
@ -7864,7 +7863,7 @@ to make one entry in the kill ring.
|
||||
|
||||
In Lisp code, optional third arg YANK-HANDLER, if non-nil,
|
||||
specifies the yank-handler text property to be set on the killed
|
||||
text. See `insert-for-yank'."
|
||||
text. See ‘insert-for-yank’."
|
||||
;; Pass point first, then mark, because the order matters
|
||||
;; when calling kill-append.
|
||||
(interactive (list (point) (mark)))
|
||||
@ -8292,9 +8291,9 @@ function:
|
||||
@smallexample
|
||||
@group
|
||||
(defun copy-region-as-kill (beg end)
|
||||
"Save the region as if killed, but don't kill it.
|
||||
"Save the region as if killed, but don’t kill it.
|
||||
In Transient Mark mode, deactivate the mark.
|
||||
If `interprogram-cut-function' is non-nil, also save the text for a window
|
||||
If ‘interprogram-cut-function’ is non-nil, also save the text for a window
|
||||
system cut and paste."
|
||||
(interactive "r")
|
||||
@end group
|
||||
@ -8593,9 +8592,9 @@ The @code{kill-new} function looks like this:
|
||||
@group
|
||||
(defun kill-new (string &optional replace yank-handler)
|
||||
"Make STRING the latest kill in the kill ring.
|
||||
Set `kill-ring-yank-pointer' to point to it.
|
||||
Set ‘kill-ring-yank-pointer’ to point to it.
|
||||
|
||||
If `interprogram-cut-function' is non-nil, apply it to STRING.
|
||||
If `interprogram-cut-function’ is non-nil, apply it to STRING.
|
||||
Optional second argument REPLACE non-nil means that STRING will replace
|
||||
the front of the kill ring, rather than being added to the list.
|
||||
@dots{}"
|
||||
@ -9268,7 +9267,7 @@ documentation string. For example:
|
||||
@smallexample
|
||||
@group
|
||||
(defvar shell-command-default-error-buffer nil
|
||||
"*Buffer name for `shell-command' @dots{} error output.
|
||||
"*Buffer name for ‘shell-command’ @dots{} error output.
|
||||
@dots{} ")
|
||||
@end group
|
||||
@end smallexample
|
||||
@ -10090,10 +10089,10 @@ With argument, rotate that many kills forward (or backward, if negative)."
|
||||
|
||||
(defun current-kill (n &optional do-not-move)
|
||||
"Rotate the yanking point by N places, and then return that kill.
|
||||
If N is zero, `interprogram-paste-function' is set, and calling it
|
||||
If N is zero, ‘interprogram-paste-function’ is set, and calling it
|
||||
returns a string, then that string is added to the front of the
|
||||
kill ring and returned as the latest kill.
|
||||
If optional arg DO-NOT-MOVE is non-nil, then don't actually move the
|
||||
If optional arg DO-NOT-MOVE is non-nil, then don’t actually move the
|
||||
yanking point; just return the Nth kill forward."
|
||||
(let ((interprogram-paste (and (= n 0)
|
||||
interprogram-paste-function
|
||||
@ -11107,7 +11106,7 @@ up the number of pebbles in a triangle.
|
||||
@smallexample
|
||||
@group
|
||||
(defun triangle-using-dotimes (number-of-rows)
|
||||
"Using dotimes, add up the number of pebbles in a triangle."
|
||||
"Using ‘dotimes’, add up the number of pebbles in a triangle."
|
||||
(let ((total 0)) ; otherwise a total is a void variable
|
||||
(dotimes (number number-of-rows total)
|
||||
(setq total (+ total (1+ number))))))
|
||||
@ -11952,7 +11951,7 @@ duo that uses recursion."
|
||||
@group
|
||||
(defun triangle-recursive-helper (sum counter number)
|
||||
"Return SUM, using COUNTER, through NUMBER inclusive.
|
||||
This is the `helper' component of a two function duo
|
||||
This is the “helper” component of a two function duo
|
||||
that uses recursion."
|
||||
(if (> counter number)
|
||||
sum
|
||||
@ -12428,10 +12427,10 @@ Here is the code for @code{forward-sentence}:
|
||||
@smallexample
|
||||
@group
|
||||
(defun forward-sentence (&optional arg)
|
||||
"Move forward to next `sentence-end'. With argument, repeat.
|
||||
With negative argument, move backward repeatedly to `sentence-beginning'.
|
||||
"Move forward to next ‘sentence-end’. With argument, repeat.
|
||||
With negative argument, move backward repeatedly to ‘sentence-beginning’.
|
||||
|
||||
The variable `sentence-end' is a regular expression that matches ends of
|
||||
The variable ‘sentence-end’ is a regular expression that matches ends of
|
||||
sentences. Also, every paragraph boundary terminates sentences as well."
|
||||
@end group
|
||||
@group
|
||||
@ -13515,8 +13514,8 @@ For example:
|
||||
@group
|
||||
(let* ((foo 7)
|
||||
(bar (* 3 foo)))
|
||||
(message "'bar' is %d." bar))
|
||||
@result{} 'bar' is 21.
|
||||
(message "‘bar’ is %d." bar))
|
||||
@result{} ‘bar’ is 21.
|
||||
@end group
|
||||
@end smallexample
|
||||
|
||||
@ -13758,7 +13757,7 @@ All this leads to the following function definition:
|
||||
"Print number of words in the region.
|
||||
Words are defined as at least one word-constituent
|
||||
character followed by at least one character that
|
||||
is not a word-constituent. The buffer's syntax
|
||||
is not a word-constituent. The buffer’s syntax
|
||||
table determines which characters these are."
|
||||
(interactive "r")
|
||||
(message "Counting words in region ... ")
|
||||
@ -13825,7 +13824,7 @@ parenthesis and type @kbd{C-x C-e} to install it.
|
||||
(defun @value{COUNT-WORDS} (beginning end)
|
||||
"Print number of words in the region.
|
||||
Words are defined as at least one word-constituent character followed
|
||||
by at least one character that is not a word-constituent. The buffer's
|
||||
by at least one character that is not a word-constituent. The buffer’s
|
||||
syntax table determines which characters these are."
|
||||
@end group
|
||||
@group
|
||||
@ -14987,13 +14986,13 @@ beginning of the file. The function definition looks like this:
|
||||
@smallexample
|
||||
@group
|
||||
(defun lengths-list-file (filename)
|
||||
"Return list of definitions' lengths within FILE.
|
||||
"Return list of definitions’ lengths within FILE.
|
||||
The returned list is a list of numbers.
|
||||
Each number is the number of words or
|
||||
symbols in one function definition."
|
||||
@end group
|
||||
@group
|
||||
(message "Working on '%s' ... " filename)
|
||||
(message "Working on ‘%s’ ... " filename)
|
||||
(save-excursion
|
||||
(let ((buffer (find-file-noselect filename))
|
||||
(lengths-list))
|
||||
@ -15759,7 +15758,7 @@ simpler to write a list manually. Here it is:
|
||||
160 170 180 190 200
|
||||
210 220 230 240 250
|
||||
260 270 280 290 300)
|
||||
"List specifying ranges for `defuns-per-range'.")
|
||||
"List specifying ranges for ‘defuns-per-range’.")
|
||||
@end group
|
||||
@end smallexample
|
||||
|
||||
@ -17522,7 +17521,7 @@ Incidentally, @code{load-library} is an interactive interface to the
|
||||
@group
|
||||
(defun load-library (library)
|
||||
"Load the library named LIBRARY.
|
||||
This is an interface to the function `load'."
|
||||
This is an interface to the function ‘load’."
|
||||
(interactive
|
||||
(list (completing-read "Load library: "
|
||||
(apply-partially 'locate-file-completion-table
|
||||
@ -19006,12 +19005,12 @@ The @code{current-kill} function is used by @code{yank} and by
|
||||
@group
|
||||
(defun current-kill (n &optional do-not-move)
|
||||
"Rotate the yanking point by N places, and then return that kill.
|
||||
If N is zero, `interprogram-paste-function' is set, and calling it
|
||||
If N is zero, ‘interprogram-paste-function’ is set, and calling it
|
||||
returns a string, then that string is added to the front of the
|
||||
kill ring and returned as the latest kill.
|
||||
@end group
|
||||
@group
|
||||
If optional arg DO-NOT-MOVE is non-nil, then don't actually move the
|
||||
If optional arg DO-NOT-MOVE is non-nil, then don’t actually move the
|
||||
yanking point; just return the Nth kill forward."
|
||||
(let ((interprogram-paste (and (= n 0)
|
||||
interprogram-paste-function
|
||||
@ -19350,8 +19349,8 @@ beginning (and mark at end). With argument N, reinsert the Nth most
|
||||
recently killed stretch of killed text.
|
||||
|
||||
When this command inserts killed text into the buffer, it honors
|
||||
`yank-excluded-properties' and `yank-handler' as described in the
|
||||
doc string for `insert-for-yank-1', which see.
|
||||
‘yank-excluded-properties’ and ‘yank-handler’ as described in the
|
||||
doc string for ‘insert-for-yank-1’, which see.
|
||||
|
||||
See also the command \\[yank-pop]."
|
||||
@end group
|
||||
@ -19925,7 +19924,7 @@ row, and the value of the width of the top line, which is calculated
|
||||
@group
|
||||
(defun Y-axis-element (number full-Y-label-width)
|
||||
"Construct a NUMBERed label element.
|
||||
A numbered element looks like this ' 5 - ',
|
||||
A numbered element looks like this ‘ 5 - ’,
|
||||
and is padded as needed so all line up with
|
||||
the element for the largest number."
|
||||
@end group
|
||||
@ -20026,7 +20025,7 @@ the @code{print-Y-axis} function, which inserts the list as a column.
|
||||
Height must be the maximum height of the graph.
|
||||
Full width is the width of the highest label element."
|
||||
;; Value of height and full-Y-label-width
|
||||
;; are passed by 'print-graph'.
|
||||
;; are passed by ‘print-graph’.
|
||||
@end group
|
||||
@group
|
||||
(let ((start (point)))
|
||||
@ -21151,7 +21150,7 @@ each column."
|
||||
@end group
|
||||
@group
|
||||
;; Value of symbol-width and full-Y-label-width
|
||||
;; are passed by 'print-graph'.
|
||||
;; are passed by ‘print-graph’.
|
||||
(let* ((leading-spaces
|
||||
(make-string full-Y-label-width ? ))
|
||||
;; symbol-width @r{is provided by} graph-body-print
|
||||
@ -21251,7 +21250,7 @@ Here are all the graphing definitions in their final form:
|
||||
110 120 130 140 150
|
||||
160 170 180 190 200
|
||||
210 220 230 240 250)
|
||||
"List specifying ranges for `defuns-per-range'.")
|
||||
"List specifying ranges for ‘defuns-per-range’.")
|
||||
@end group
|
||||
|
||||
@group
|
||||
@ -21312,14 +21311,14 @@ as graph-symbol.")
|
||||
@smallexample
|
||||
@group
|
||||
(defun lengths-list-file (filename)
|
||||
"Return list of definitions' lengths within FILE.
|
||||
"Return list of definitions’ lengths within FILE.
|
||||
The returned list is a list of numbers.
|
||||
Each number is the number of words or
|
||||
symbols in one function definition."
|
||||
@end group
|
||||
|
||||
@group
|
||||
(message "Working on '%s' ... " filename)
|
||||
(message "Working on ‘%s’ ... " filename)
|
||||
(save-excursion
|
||||
(let ((buffer (find-file-noselect filename))
|
||||
(lengths-list))
|
||||
@ -21449,7 +21448,7 @@ The strings are either graph-blank or graph-symbol."
|
||||
@group
|
||||
(defun Y-axis-element (number full-Y-label-width)
|
||||
"Construct a NUMBERed label element.
|
||||
A numbered element looks like this ' 5 - ',
|
||||
A numbered element looks like this ‘ 5 - ’,
|
||||
and is padded as needed so all line up with
|
||||
the element for the largest number."
|
||||
@end group
|
||||
@ -21479,7 +21478,7 @@ Optionally, print according to VERTICAL-STEP."
|
||||
@end group
|
||||
@group
|
||||
;; Value of height and full-Y-label-width
|
||||
;; are passed by 'print-graph'.
|
||||
;; are passed by ‘print-graph’.
|
||||
(let ((start (point)))
|
||||
(insert-rectangle
|
||||
(Y-axis-column height full-Y-label-width vertical-step))
|
||||
@ -21644,7 +21643,7 @@ each column."
|
||||
@end group
|
||||
@group
|
||||
;; Value of symbol-width and full-Y-label-width
|
||||
;; are passed by 'print-graph'.
|
||||
;; are passed by ‘print-graph’.
|
||||
(let* ((leading-spaces
|
||||
(make-string full-Y-label-width ? ))
|
||||
;; symbol-width @r{is provided by} graph-body-print
|
||||
|
@ -315,7 +315,7 @@ between a few different constant values:
|
||||
@example
|
||||
(pcase (get-return-code x)
|
||||
(`success (message "Done!"))
|
||||
(`would-block (message "Sorry, can't do it now"))
|
||||
(`would-block (message "Sorry, can’t do it now"))
|
||||
(`read-only (message "The shmliblick is read-only"))
|
||||
(`access-denied (message "You do not have the needed rights"))
|
||||
(code (message "Unknown return code %S" code)))
|
||||
|
@ -632,13 +632,13 @@ for logging the warning. By default, it is @file{*Warnings*}.
|
||||
@end defun
|
||||
|
||||
@defun lwarn type level message &rest args
|
||||
This function reports a warning using the value of @code{(format
|
||||
This function reports a warning using the value of @code{(format-message
|
||||
@var{message} @var{args}...)} as the message in the @file{*Warnings*}
|
||||
buffer. In other respects it is equivalent to @code{display-warning}.
|
||||
@end defun
|
||||
|
||||
@defun warn message &rest args
|
||||
This function reports a warning using the value of @code{(format
|
||||
This function reports a warning using the value of @code{(format-message
|
||||
@var{message} @var{args}...)} as the message, @code{(emacs)} as the
|
||||
type, and @code{:warning} as the severity level. It exists for
|
||||
compatibility only; we recommend not using it, because you should
|
||||
|
@ -1561,7 +1561,7 @@ Around advice such as:
|
||||
|
||||
@example
|
||||
(defadvice foo (around foo-around)
|
||||
"Ignore case in `foo'."
|
||||
"Ignore case in ‘foo’."
|
||||
(let ((case-fold-search t))
|
||||
ad-do-it))
|
||||
(ad-activate 'foo)
|
||||
@ -1571,7 +1571,7 @@ could translate into:
|
||||
|
||||
@example
|
||||
(defun foo--foo-around (orig-fun &rest args)
|
||||
"Ignore case in `foo'."
|
||||
"Ignore case in ‘foo’."
|
||||
(let ((case-fold-search t))
|
||||
(apply orig-fun args)))
|
||||
(advice-add 'foo :around #'foo--foo-around)
|
||||
|
@ -1155,9 +1155,9 @@ Many other modes, such as `mail-mode', `outline-mode' and
|
||||
"Major mode for editing text written for humans to read.
|
||||
In this mode, paragraphs are delimited only by blank or white lines.
|
||||
You can thus get the full benefit of adaptive filling
|
||||
(see the variable `adaptive-fill-mode').
|
||||
(see the variable ‘adaptive-fill-mode’).
|
||||
\\@{text-mode-map@}
|
||||
Turning on Text mode runs the normal hook `text-mode-hook'."
|
||||
Turning on Text mode runs the normal hook ‘text-mode-hook’."
|
||||
@end group
|
||||
@group
|
||||
(set (make-local-variable 'text-mode-variant) t)
|
||||
@ -1252,7 +1252,7 @@ And here is the code to set up the keymap for Lisp mode:
|
||||
@dots{}
|
||||
map)
|
||||
"Keymap for ordinary Lisp mode.
|
||||
All commands in `lisp-mode-shared-map' are inherited by this map.")
|
||||
All commands in ‘lisp-mode-shared-map’ are inherited by this map.")
|
||||
@end group
|
||||
@end smallexample
|
||||
|
||||
@ -1268,12 +1268,12 @@ Delete converts tabs to spaces as it moves back.
|
||||
Blank lines separate paragraphs. Semicolons start comments.
|
||||
|
||||
\\@{lisp-mode-map@}
|
||||
Note that `run-lisp' may be used either to start an inferior Lisp job
|
||||
Note that ‘run-lisp’ may be used either to start an inferior Lisp job
|
||||
or to switch back to an existing one.
|
||||
@end group
|
||||
|
||||
@group
|
||||
Entry to this mode calls the value of `lisp-mode-hook'
|
||||
Entry to this mode calls the value of ‘lisp-mode-hook’
|
||||
if that value is non-nil."
|
||||
(lisp-mode-variables nil t)
|
||||
(set (make-local-variable 'find-tag-default-function)
|
||||
@ -1447,7 +1447,7 @@ will load the library that defines the mode. For example:
|
||||
(defcustom msb-mode nil
|
||||
"Toggle msb-mode.
|
||||
Setting this variable directly does not take effect;
|
||||
use either \\[customize] or the function `msb-mode'."
|
||||
use either \\[customize] or the function ‘msb-mode’."
|
||||
:set 'custom-set-minor-mode
|
||||
:initialize 'custom-initialize-default
|
||||
:version "20.4"
|
||||
@ -1605,7 +1605,7 @@ for this macro.
|
||||
Interactively with no argument, this command toggles the mode.
|
||||
A positive prefix argument enables the mode, any other prefix
|
||||
argument disables it. From Lisp, argument omitted or nil enables
|
||||
the mode, `toggle' toggles the state.
|
||||
the mode, ‘toggle’ toggles the state.
|
||||
|
||||
When Hungry mode is enabled, the control delete key
|
||||
gobbles all preceding whitespace except the last.
|
||||
|
@ -1927,7 +1927,7 @@ idleness. Here's an example:
|
||||
|
||||
@example
|
||||
(defvar my-resume-timer nil
|
||||
"Timer for `my-timer-function' to reschedule itself, or nil.")
|
||||
"Timer for ‘my-timer-function’ to reschedule itself, or nil.")
|
||||
|
||||
(defun my-timer-function ()
|
||||
;; @r{If the user types a command while @code{my-resume-timer}}
|
||||
|
@ -969,12 +969,12 @@ is not truncated.
|
||||
|
||||
@example
|
||||
@group
|
||||
(format "The word '%7s' has %d letters in it."
|
||||
(format "The word ‘%7s’ has %d letters in it."
|
||||
"foo" (length "foo"))
|
||||
@result{} "The word ' foo' has 3 letters in it."
|
||||
(format "The word '%7s' has %d letters in it."
|
||||
@result{} "The word ‘ foo’ has 3 letters in it."
|
||||
(format "The word ‘%7s’ has %d letters in it."
|
||||
"specification" (length "specification"))
|
||||
@result{} "The word 'specification' has 13 letters in it."
|
||||
@result{} "The word ‘specification’ has 13 letters in it."
|
||||
@end group
|
||||
@end example
|
||||
|
||||
@ -1013,12 +1013,12 @@ ignored.
|
||||
(format "%06d is padded on the left with zeros" 123)
|
||||
@result{} "000123 is padded on the left with zeros"
|
||||
|
||||
(format "'%-6d' is padded on the right" 123)
|
||||
@result{} "'123 ' is padded on the right"
|
||||
(format "‘%-6d’ is padded on the right" 123)
|
||||
@result{} "‘123 ’ is padded on the right"
|
||||
|
||||
(format "The word '%-7s' actually has %d letters in it."
|
||||
(format "The word ‘%-7s’ actually has %d letters in it."
|
||||
"foo" (length "foo"))
|
||||
@result{} "The word 'foo ' actually has 3 letters in it."
|
||||
@result{} "The word ‘foo ’ actually has 3 letters in it."
|
||||
@end group
|
||||
@end example
|
||||
|
||||
|
@ -1960,7 +1960,7 @@ Called from a program, there are three arguments:
|
||||
@group
|
||||
REVERSE (non-nil means reverse order),\
|
||||
BEG and END (region to sort).
|
||||
The variable `sort-fold-case' determines\
|
||||
The variable ‘sort-fold-case’ determines\
|
||||
whether alphabetic case affects
|
||||
the sort order."
|
||||
@end group
|
||||
|
@ -867,14 +867,14 @@ It would look like this:
|
||||
)
|
||||
|
||||
(defun MY-ROOT-FCN ()
|
||||
"Return the root fcn for `default-directory'"
|
||||
"Return the root fcn for ‘default-directory’"
|
||||
;; You might be able to use 'ede-cpp-root-project-root'
|
||||
;; and not write this at all.
|
||||
)
|
||||
|
||||
(defun MY-LOAD (dir)
|
||||
"Load a project of type `cpp-root' for the directory DIR.
|
||||
Return nil if there isn't one."
|
||||
"Load a project of type ‘cpp-root’ for the directory DIR.
|
||||
Return nil if there isn’t one."
|
||||
;; Use your preferred construction method here.
|
||||
(ede-cpp-root-project "NAME" :file (expand-file-name "FILE" dir)
|
||||
:locate-fcn 'MYFCN)
|
||||
|
@ -4336,7 +4336,7 @@ best fix I've been able to come up with:
|
||||
|
||||
@lisp
|
||||
(defun rmail-reply-t ()
|
||||
"Reply only to the sender of the current message. (See rmail-reply.)"
|
||||
"Reply only to the sender of the current message. (See ‘rmail-reply’.)"
|
||||
(interactive)
|
||||
(rmail-reply t))
|
||||
|
||||
|
@ -1529,7 +1529,7 @@ Currently, the default superclass is defined as follows:
|
||||
nil
|
||||
"Default parent class for classes with no specified parent class.
|
||||
Its slots are automatically adopted by classes with no specified
|
||||
parents. This class is not stored in the `parent' slot of a class vector."
|
||||
parents. This class is not stored in the ‘parent’ slot of a class vector."
|
||||
:abstract t)
|
||||
@end example
|
||||
|
||||
|
@ -1671,7 +1671,7 @@ instead (works for newer versions as well):
|
||||
(setq message-user-fqdn fqdn)
|
||||
(gnus-message 1 "Redefining `message-make-fqdn'.")
|
||||
(defun message-make-fqdn ()
|
||||
"Return user's fully qualified domain name."
|
||||
"Return user’s fully qualified domain name."
|
||||
fqdn))))
|
||||
@end example
|
||||
@noindent
|
||||
@ -1765,9 +1765,9 @@ snippet by Frank Haun <pille3003@@fhaun.de> in
|
||||
|
||||
@example
|
||||
(defun my-archive-article (&optional n)
|
||||
"Copies one or more article(s) to a corresponding `nnml:' group, e.g.,
|
||||
`gnus.ding' goes to `nnml:1.gnus.ding'. And `nnml:List-gnus.ding' goes
|
||||
to `nnml:1.List-gnus-ding'.
|
||||
"Copies one or more article(s) to a corresponding ‘nnml:’ group, e.g.,
|
||||
‘gnus.ding’ goes to ‘nnml:1.gnus.ding’. And ‘nnml:List-gnus.ding’ goes
|
||||
to ‘nnml:1.List-gnus-ding’.
|
||||
|
||||
Use process marks or mark a region in the summary buffer to archive
|
||||
more then one article."
|
||||
|
@ -21033,8 +21033,8 @@ function:
|
||||
|
||||
@lisp
|
||||
(defun gnus-decay-score (score)
|
||||
"Decay SCORE according to `gnus-score-decay-constant'
|
||||
and `gnus-score-decay-scale'."
|
||||
"Decay SCORE according to ‘gnus-score-decay-constant’
|
||||
and ‘gnus-score-decay-scale’."
|
||||
(let ((n (- score
|
||||
(* (if (< score 0) -1 1)
|
||||
(min (abs score)
|
||||
@ -24080,7 +24080,7 @@ spam. And here is the nifty function:
|
||||
|
||||
@lisp
|
||||
(defun my-gnus-raze-spam ()
|
||||
"Submit SPAM to Vipul's Razor, then mark it as expirable."
|
||||
"Submit SPAM to Vipul’s Razor, then mark it as expirable."
|
||||
(interactive)
|
||||
(gnus-summary-save-in-pipe "razor-report -f -d" t)
|
||||
(gnus-summary-mark-as-expirable 1))
|
||||
|
@ -3159,13 +3159,13 @@ code to @file{~/.emacs}.
|
||||
@smalllisp
|
||||
@group
|
||||
(defvar my-mh-screen-saved nil
|
||||
"Set to non-@code{nil} when MH-E window configuration shown.")
|
||||
"Set to non-nil when MH-E window configuration shown.")
|
||||
(defvar my-normal-screen nil "Normal window configuration.")
|
||||
(defvar my-mh-screen nil "MH-E window configuration.")
|
||||
|
||||
(defun my-mh-rmail (&optional arg)
|
||||
"Toggle between MH-E and normal screen configurations.
|
||||
With non-@code{nil} or prefix argument, @i{inc} mailbox as well
|
||||
With non-nil or prefix argument, include mailbox as well
|
||||
when going into mail."
|
||||
(interactive "P") ; @r{user callable function, P=prefix arg}
|
||||
(setq my-mh-screen-saved ; @r{save state}
|
||||
@ -3474,7 +3474,7 @@ bindings, for example:
|
||||
@smalllisp
|
||||
@group
|
||||
(defvar my-mh-init-done nil
|
||||
"Non-@code{nil} when one-time MH-E settings made.")
|
||||
"Non-nil when one-time MH-E settings made.")
|
||||
|
||||
(defun my-mh-folder-mode-hook ()
|
||||
"Hook to set key bindings in MH-Folder mode."
|
||||
|
@ -909,7 +909,7 @@ The real answer, therefore, is a @code{/reconnect} command:
|
||||
"Reconnect the server process."
|
||||
(interactive "i")
|
||||
(unless process
|
||||
(error "There's no process for this target"))
|
||||
(error "There’s no process for this target"))
|
||||
(let* ((server (car (process-contact process)))
|
||||
(port (process-contact process :service))
|
||||
(nick (rcirc-nick process))
|
||||
|
@ -1046,7 +1046,7 @@ the data area, such as hidden constants you want to refer to in your
|
||||
formulas.
|
||||
|
||||
You can override the variable @code{ses--symbolic-formulas} to be a list of
|
||||
symbols (as parenthesized strings) to show as completions for the '
|
||||
symbols (as parenthesized strings) to show as completions for the @kbd{'}
|
||||
command. This initial completions list is used instead of the actual
|
||||
set of symbols-as-formulas in the spreadsheet.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user