Commit 4837b516 authored by Glenn Morris's avatar Glenn Morris
Browse files

Replace `iff' in doc-strings and comments.

parent 5453fa41
......@@ -39,9 +39,9 @@ define global abbrevs instead."
(defun abbrev-mode (&optional arg)
"Toggle Abbrev mode in the current buffer.
With argument ARG, turn abbrev mode on iff ARG is positive.
In Abbrev mode, inserting an abbreviation causes it to expand
and be replaced by its expansion."
With optional argument ARG, turn abbrev mode on if ARG is
positive, otherwise turn it off. In Abbrev mode, inserting an
abbreviation causes it to expand and be replaced by its expansion."
(interactive "P")
(setq abbrev-mode
(if (null arg) (not abbrev-mode)
......
......@@ -1658,8 +1658,9 @@ the following two lines in your Emacs init file:
"Toggle minor mode for controlling exposure and editing of text outlines.
\\<allout-mode-map>
Optional arg forces mode to re-initialize iff arg is positive num or
symbol. Allout outline mode always runs as a minor mode.
Optional prefix argument TOGGLE forces the mode to re-initialize
if it is positive, otherwise it turns the mode off. Allout
outline mode always runs as a minor mode.
Allout outline mode provides extensive outline oriented formatting and
manipulation. It enables structural editing of outlines, as well as
......
......@@ -315,7 +315,7 @@ This function is designed to be added to hooks, for example:
;;;###autoload
(define-minor-mode auto-revert-tail-mode
"Toggle reverting tail of buffer when file on disk grows.
With arg, turn Tail mode on iff arg is positive.
With arg, turn Tail mode on if arg is positive, otherwise turn it off.
When Tail mode is enabled, the tail of the file is constantly
followed, as with the shell command `tail -f'. This means that
......
......@@ -476,7 +476,7 @@ Menu of mode operations in the mode line.")
(defvar minor-mode-alist nil "\
Alist saying how to show minor modes in the mode line.
Each element looks like (VARIABLE STRING);
STRING is included in the mode line iff VARIABLE's value is non-nil.
STRING is included in the mode line if VARIABLE's value is non-nil.
Actually, STRING need not be a string; any possible mode-line element
is okay. See `mode-line-format'.")
......
......@@ -642,7 +642,7 @@ this sets the local binding in that buffer instead."
(funcall variable (if value 1 0))))
(defun custom-quote (sexp)
"Quote SEXP iff it is not self quoting."
"Quote SEXP if it is not self quoting."
(if (or (memq sexp '(t nil))
(keywordp sexp)
(and (listp sexp)
......@@ -665,14 +665,14 @@ default value. Otherwise, set it to nil.
To actually save the value, call `custom-save-all'.
Return non-nil iff the `saved-value' property actually changed."
Return non-nil if the `saved-value' property actually changed."
(custom-load-symbol symbol)
(let* ((get (or (get symbol 'custom-get) 'default-value))
(value (funcall get symbol))
(saved (get symbol 'saved-value))
(standard (get symbol 'standard-value))
(comment (get symbol 'customized-variable-comment)))
;; Save default value iff different from standard value.
;; Save default value if different from standard value.
(if (or (null standard)
(not (equal value (condition-case nil
(eval (car standard))
......@@ -694,13 +694,13 @@ or else if it is different from the standard value, set the
`customized-value' property to a list whose car evaluates to the
default value. Otherwise, set it to nil.
Return non-nil iff the `customized-value' property actually changed."
Return non-nil if the `customized-value' property actually changed."
(custom-load-symbol symbol)
(let* ((get (or (get symbol 'custom-get) 'default-value))
(value (funcall get symbol))
(customized (get symbol 'customized-value))
(old (or (get symbol 'saved-value) (get symbol 'standard-value))))
;; Mark default value as set iff different from old value.
;; Mark default value as set if different from old value.
(if (not (and old
(equal value (condition-case nil
(eval (car old))
......
......@@ -62,7 +62,8 @@
(defun diff-sentinel (code)
"Code run when the diff process exits.
CODE is the exit code of the process. It should be 0 iff no diffs were found."
CODE is the exit code of the process. It should be 0 only if no diffs
were found."
(if diff-old-temp-file (delete-file diff-old-temp-file))
(if diff-new-temp-file (delete-file diff-new-temp-file))
(save-excursion
......
......@@ -2006,8 +2006,8 @@ of marked files. If KILL-ROOT is non-nil, kill DIRNAME as well."
(defun dired-tree-lessp (dir1 dir2)
;; Lexicographic order on file name components, like `ls -lR':
;; DIR1 < DIR2 iff DIR1 comes *before* DIR2 in an `ls -lR' listing,
;; i.e., iff DIR1 is a (grand)parent dir of DIR2,
;; DIR1 < DIR2 if DIR1 comes *before* DIR2 in an `ls -lR' listing,
;; i.e., if DIR1 is a (grand)parent dir of DIR2,
;; or DIR1 and DIR2 are in the same parentdir and their last
;; components are string-lessp.
;; Thus ("/usr/" "/usr/bin") and ("/usr/a/" "/usr/b/") are tree-lessp.
......
......@@ -186,7 +186,8 @@ use either \\[customize] or the function `double-mode'."
;;;###autoload
(defun double-mode (arg)
"Toggle Double mode.
With prefix arg, turn Double mode on iff arg is positive.
With prefix argument ARG, turn Double mode on if ARG is positive, otherwise
turn it off.
When Double mode is on, some keys will insert different strings
when pressed twice. See variable `double-map' for details."
......
......@@ -867,7 +867,7 @@ one optional arguments, diff-number to refine.")
(ediff-make-fine-diffs n 'noforce)
(ediff-make-fine-diffs n 'skip)))
;; highlight iff fine diffs already exist
;; highlight if fine diffs already exist
((eq ediff-auto-refine 'off)
(ediff-make-fine-diffs n 'skip))))
......@@ -1459,7 +1459,7 @@ arguments to `skip-chars-forward'."
(defun ediff-same-contents (d1 d2 &optional filter-re)
"Returns t iff D1 and D2 have the same content.
"Return t if D1 and D2 have the same content.
D1 and D2 can either be both directories or both regular files.
Symlinks and the likes are not handled.
If FILTER-RE is non-nil, recursive checking in directories
......
......@@ -3941,8 +3941,9 @@ prints a message in the minibuffer. Instead, use `set-buffer-modified-p'."
(defun toggle-read-only (&optional arg)
"Change whether this buffer is visiting its file read-only.
With arg, set read-only iff arg is positive.
If visiting file read-only and `view-read-only' is non-nil, enter view mode."
With prefix argument ARG, make the buffer read-only if ARG is
positive, otherwise make it writable. If visiting file read-only
and `view-read-only' is non-nil, enter view mode."
(interactive "P")
(if (and arg
(if (> (prefix-numeric-value arg) 0) buffer-read-only
......@@ -4568,7 +4569,7 @@ FILENAME should lack slashes. You can redefine this for customization."
(defun wildcard-to-regexp (wildcard)
"Given a shell file name pattern WILDCARD, return an equivalent regexp.
The generated regexp will match a filename iff the filename
The generated regexp will match a filename only if the filename
matches that wildcard according to shell rules. Only wildcards known
by `sh' are supported."
(let* ((i (string-match "[[.*+\\^$?]" wildcard))
......
......@@ -355,7 +355,7 @@ Each element in a user-level keywords list should have one of these forms:
where MATCHER can be either the regexp to search for, or the function name to
call to make the search (called with one argument, the limit of the search;
it should return non-nil, move point, and set `match-data' appropriately iff
it should return non-nil, move point, and set `match-data' appropriately if
it succeeds; like `re-search-forward' would).
MATCHER regexps can be generated via the function `regexp-opt'.
......@@ -1068,7 +1068,7 @@ that tries to find such elements and move the boundaries such that they do
not fall in the middle of one.
Each function is called with no argument; it is expected to adjust the
dynamically bound variables `font-lock-beg' and `font-lock-end'; and return
non-nil iff it did make such an adjustment.
non-nil if it did make such an adjustment.
These functions are run in turn repeatedly until they all return nil.
Put first the functions more likely to cause a change and cheaper to compute.")
;; Mark it as a special hook which doesn't use any global setting
......@@ -1746,7 +1746,7 @@ A LEVEL of nil is equal to a LEVEL of 0, a LEVEL of t is equal to
"Set fontification defaults appropriately for this mode.
Sets various variables using `font-lock-defaults' (or, if nil, using
`font-lock-defaults-alist') and `font-lock-maximum-decoration'."
;; Set fontification defaults iff not previously set for correct major mode.
;; Set fontification defaults if not previously set for correct major mode.
(unless (and font-lock-set-defaults
(eq font-lock-mode-major-mode major-mode))
(setq font-lock-mode-major-mode major-mode)
......
......@@ -1310,9 +1310,9 @@ itself as a pre-command hook."
(define-minor-mode blink-cursor-mode
"Toggle blinking cursor mode.
With a numeric argument, turn blinking cursor mode on iff ARG is positive.
When blinking cursor mode is enabled, the cursor of the selected
window blinks.
With a numeric argument, turn blinking cursor mode on if ARG is positive,
otherwise turn it off. When blinking cursor mode is enabled, the
cursor of the selected window blinks.
Note that this command is effective only when Emacs
displays through a window system, because then Emacs does its own
......
......@@ -131,7 +131,7 @@
;; an example, if the value is `buffer-file-name' then all buffers
;; who are visiting files are suitable, but others (like dired
;; buffers) are not;
;; * a list -- then the buffer is suitable iff its mode is in the
;; * a list -- then the buffer is suitable if its mode is in the
;; list, except if the first element is `not', in which case the test
;; is reversed (i.e. it is a list of unsuitable modes).
;; * Otherwise, the buffer is suitable if its name does not begin with
......
......@@ -1331,7 +1331,7 @@ If a buffer has no filename, it is ignored.
With no prefix arg, use the filename sans its directory of each marked file.
With a zero prefix arg, use the complete filename of each marked file.
With \\[universal-argument], use the filename of each marked file relative
to `ibuffer-default-directory' iff non-nil, otherwise `default-directory'.
to `ibuffer-default-directory' if non-nil, otherwise `default-directory'.
You can then feed the file name(s) to other commands with \\[yank]."
(interactive "p")
......
......@@ -1835,7 +1835,7 @@ If point is on a group name, this function operates on that group."
(defun ibuffer-map-lines (function &optional nomodify group)
"Call FUNCTION for each buffer.
Don't set the ibuffer modification flag iff NOMODIFY is non-nil.
Set the ibuffer modification flag unless NOMODIFY is non-nil.
If optional argument GROUP is non-nil, then only call FUNCTION on
buffers in filtering group GROUP.
......@@ -2267,7 +2267,7 @@ If optional arg SILENT is non-nil, do not display progress messages."
(defun ibuffer-quit ()
"Quit this `ibuffer' session.
Try to restore the previous window configuration iff
Try to restore the previous window configuration if
`ibuffer-restore-window-config-on-quit' is non-nil."
(interactive)
(if ibuffer-restore-window-config-on-quit
......
......@@ -99,7 +99,7 @@ completions - see `icomplete-delay-completions-threshold'."
(defcustom icomplete-minibuffer-setup-hook nil
"*Icomplete-specific customization of minibuffer setup.
This hook is run during minibuffer setup iff icomplete will be active.
This hook is run during minibuffer setup if icomplete is active.
It is intended for use in customizing icomplete for interoperation
with other features and packages. For instance:
......@@ -168,7 +168,8 @@ except those on this list.")
;;;###autoload
(define-minor-mode icomplete-mode
"Toggle incremental minibuffer completion for this Emacs session.
With a numeric argument, turn Icomplete mode on iff ARG is positive."
With a numeric argument, turn Icomplete mode on if ARG is positive,
otherwise turn it off."
:global t :group 'icomplete
(if icomplete-mode
;; The following is not really necessary after first time -
......
......@@ -898,7 +898,7 @@ See documentation of `walk-windows' for useful values.")
(defcustom ido-minibuffer-setup-hook nil
"*Ido-specific customization of minibuffer setup.
This hook is run during minibuffer setup iff `ido' will be active.
This hook is run during minibuffer setup if `ido' is active.
It is intended for use in customizing ido for interoperation
with other packages. For instance:
......
......@@ -342,7 +342,7 @@ Image types are symbols like `xbm' or `jpeg'."
;;;###autoload
(defun image-type-auto-detected-p ()
"Return t iff the current buffer contains an auto-detectable image.
"Return t if the current buffer contains an auto-detectable image.
This function is intended to be used from `magic-fallback-mode-alist'.
The buffer is considered to contain an auto-detectable image if
......
......@@ -727,7 +727,7 @@ definitions, etc. It contains a substring which is the name to
appear in the menu. See the info section on Regexps for more
information. REGEXP may also be a function, called without
arguments. It is expected to search backwards. It shall return
true and set `match-data' iff it finds another element.
true and set `match-data' if it finds another element.
INDEX points to the substring in REGEXP that contains the
name (of the function, variable or type) that is to appear in the
......
......@@ -144,7 +144,7 @@ to `symbol', and the help mode defaults to the current major mode."
(apply 'info-lookup-add-help* nil arg))
(defun info-lookup-maybe-add-help (&rest arg)
"Add a help specification iff none is defined.
"Add a help specification if none is defined.
See the documentation of the function `info-lookup-add-help'
for more details."
(apply 'info-lookup-add-help* t arg))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment