diff options
-rw-r--r-- | generic/proof.el | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/generic/proof.el b/generic/proof.el index bab2d3d0..ab51aa1e 100644 --- a/generic/proof.el +++ b/generic/proof.el @@ -194,6 +194,19 @@ It was constructed with the macro proof-customize-toggle.") (if (null arg) (not ,var) (> (prefix-numeric-value arg) 0))))) +;; FIXME: combine this with above, and remove messing calls in +;; proof-script. +;; FIXME: rather broken wrt to ARG. +(defmacro proof-deftoggle (var) + "Define a function VAR-toggle to be a toggler for variable VAR. +See proof-customize-toggle." + `(defun ,(intern (concat (symbol-name var) "-toggle")) (arg) + (interactive "P") + (customize-set-variable + (quote ,var) + (if (null arg) (not ,var) + (> (prefix-numeric-value arg) 0))))) + (defun proof-try-require (symbol) "Try requiring SYMBOL. No error if the file for SYMBOL isn't found." (condition-case () |