Function: Texinfo-arg-on|off

Texinfo-arg-on|off is a byte-compiled function defined in tex-info.el.

Signature

(Texinfo-arg-on|off OPTIONAL &optional PROMPT STYLE)

Documentation

Prompt for a boolean input.

OPTIONAL is ignored. Use PROMPT as the prompt string. STYLE may be one of :on|off or :true|false, if omitted :on|off is assumed by default.

Source Code

;; Defined in ~/.emacs.d/elpa/auctex-14.1.2/tex-info.el
(defun Texinfo-arg-on|off (optional &optional prompt style)
  "Prompt for a boolean input.
OPTIONAL is ignored.
Use PROMPT as the prompt string.
STYLE may be one of `:on|off' or `:true|false', if omitted `:on|off'
is assumed by default."
(let ((collection  (cdr (assq style
                         '((nil . #1=("on" "off"))
                           (:on|off . #1#)
                           (:true|false "true" "false"))))))
  (insert (if (y-or-n-p  (TeX-argument-prompt optional prompt (concat (car collection) ", not " (cadr collection))))
                         (car collection)
            (cadr collection)))))