# HG changeset patch # User Richard M. Stallman # Date 860834141 0 # Node ID f967f12c8ec8807d3b7d806e63ec021b34072685 # Parent 9fa0ed8da0b1f27f4f306decdc7ecaa319d1ce29 Add defgroup's; use defcustom for user vars. diff -r 9fa0ed8da0b1 -r f967f12c8ec8 lisp/emacs-lisp/edebug.el --- a/lisp/emacs-lisp/edebug.el Sat Apr 12 04:15:03 1997 +0000 +++ b/lisp/emacs-lisp/edebug.el Sat Apr 12 08:35:41 1997 +0000 @@ -1,6 +1,7 @@ ;;; edebug.el --- a source-level debugger for Emacs Lisp -;; Copyright (C) 1988,'89,'90,'91,'92,'93,'94,'95 Free Software Foundation, Inc +;; Copyright (C) 1988,'89,'90,'91,'92,'93,'94,'95,'97 +;; Free Software Foundation, Inc ;; Author: Daniel LaLiberte ;; Keywords: lisp, tools, maint @@ -8,7 +9,7 @@ ;; LCD Archive Entry: ;; edebug|Daniel LaLiberte|liberte@cs.uiuc.edu ;; |A source level debugger for Emacs Lisp. -;; |$Date: 1996/11/09 21:48:07 $|$Revision: 3.12 $|~/modes/edebug.el| +;; |$Date: 1996/12/26 20:46:51 $|$Revision: 3.13 $|~/modes/edebug.el| ;; This file is part of GNU Emacs. @@ -85,7 +86,7 @@ ;;; Code: (defconst edebug-version - (let ((raw-version "$Revision: 3.12 $")) + (let ((raw-version "$Revision: 3.13 $")) (substring raw-version (string-match "[0-9.]*" raw-version) (match-end 0)))) @@ -126,14 +127,21 @@ ;;; Options -(defvar edebug-setup-hook nil +(defgroup edebug nil + "A source-level debugger for Emacs Lisp" + :group 'lisp) + + +(defcustom edebug-setup-hook nil "*Functions to call before edebug is used. Each time it is set to a new value, Edebug will call those functions once and then `edebug-setup-hook' is reset to nil. You could use this to load up Edebug specifications associated with a package you are -using but only when you also use Edebug.") - -(defvar edebug-all-defs nil +using but only when you also use Edebug." + :type 'hook + :group 'edebug) + +(defcustom edebug-all-defs nil "*If non-nil, evaluation of any defining forms will instrument for Edebug. This applies to `eval-defun', `eval-region', `eval-buffer', and `eval-current-buffer'. `eval-region' is also called by @@ -142,14 +150,18 @@ You can use the command `edebug-all-defs' to toggle the value of this variable. You may wish to make it local to each buffer with \(make-local-variable 'edebug-all-defs) in your -`emacs-lisp-mode-hook'.") - -(defvar edebug-all-forms nil +`emacs-lisp-mode-hook'." + :type 'boolean + :group 'edebug) + +(defcustom edebug-all-forms nil "*Non-nil evaluation of all forms will instrument for Edebug. This doesn't apply to loading or evaluations in the minibuffer. -Use the command `edebug-all-forms' to toggle the value of this option.") - -(defvar edebug-eval-macro-args nil +Use the command `edebug-all-forms' to toggle the value of this option." + :type 'boolean + :group 'edebug) + +(defcustom edebug-eval-macro-args nil "*Non-nil means all macro call arguments may be evaluated. If this variable is nil, the default, Edebug will *not* wrap macro call arguments as if they will be evaluated. @@ -157,15 +169,19 @@ So to specify exceptions for macros that have some arguments evaluated and some not, you should specify an `edebug-form-spec'. -This option is going away soon.") - -(defvar edebug-stop-before-symbols nil +This option is going away soon." + :type 'boolean + :group 'edebug) + +(defcustom edebug-stop-before-symbols nil "*Non-nil causes Edebug to stop before symbols as well as after. In any case, a breakpoint or interrupt may stop before a symbol. -This option is going away soon.") - -(defvar edebug-save-windows t +This option is going away soon." + :type 'boolean + :group 'edebug) + +(defcustom edebug-save-windows t "*If non-nil, Edebug saves and restores the window configuration. That takes some time, so if your program does not care what happens to the window configurations, it is better to set this variable to nil. @@ -173,9 +189,11 @@ If the value is a list, only the listed windows are saved and restored. -`edebug-toggle-save-windows' may be used to change this variable.") - -(defvar edebug-save-displayed-buffer-points nil +`edebug-toggle-save-windows' may be used to change this variable." + :type '(choice boolean (repeat string)) + :group 'edebug) + +(defcustom edebug-save-displayed-buffer-points nil "*If non-nil, save and restore point in all displayed buffers. Saving and restoring point in other buffers is necessary if you are @@ -185,50 +203,71 @@ Saving and restoring point in all buffers is expensive, since it requires selecting each window twice, so enable this only if you need -it.") - -(defvar edebug-initial-mode 'step +it." + :type 'boolean + :group 'edebug) + +(defcustom edebug-initial-mode 'step "*Initial execution mode for Edebug, if non-nil. If this variable is non-@code{nil}, it specifies the initial execution mode for Edebug when it is first activated. Possible values are step, next, go, -Go-nonstop, trace, Trace-fast, continue, and Continue-fast.") - -(defvar edebug-trace nil +Go-nonstop, trace, Trace-fast, continue, and Continue-fast." + :type '(choice (const step) (const next) (const go) + (const Go-nonstop) (const trace) + (const Trace-fast) (const continue) + (const continue-fast)) + :group 'edebug) + +(defcustom edebug-trace nil "*Non-nil means display a trace of function entry and exit. Tracing output is displayed in a buffer named `*edebug-trace*', one function entry or exit per line, indented by the recursion level. You can customize by replacing functions `edebug-print-trace-before' -and `edebug-print-trace-after'.") - -(defvar edebug-test-coverage nil +and `edebug-print-trace-after'." + :type 'boolean + :group 'edebug) + +(defcustom edebug-test-coverage nil "*If non-nil, Edebug tests coverage of all expressions debugged. This is done by comparing the result of each expression with the previous result. Coverage is considered OK if two different results are found. Use `edebug-display-freq-count' to display the frequency count and -coverage information for a definition.") - -(defvar edebug-continue-kbd-macro nil +coverage information for a definition." + :type 'boolean + :group 'edebug) + +(defcustom edebug-continue-kbd-macro nil "*If non-nil, continue defining or executing any keyboard macro. -Use this with caution since it is not debugged.") - - -(defvar edebug-print-length 50 - "*Default value of `print-length' to use while printing results in Edebug.") -(defvar edebug-print-level 50 - "*Default value of `print-level' to use while printing results in Edebug.") -(defvar edebug-print-circle t - "*Default value of `print-circle' to use while printing results in Edebug.") - -(defvar edebug-unwrap-results nil +Use this with caution since it is not debugged." + :type 'boolean + :group 'edebug) + + +(defcustom edebug-print-length 50 + "*Default value of `print-length' to use while printing results in Edebug." + :type 'integer + :group 'edebug) +(defcustom edebug-print-level 50 + "*Default value of `print-level' to use while printing results in Edebug." + :type 'integer + :group 'edebug) +(defcustom edebug-print-circle t + "*Default value of `print-circle' to use while printing results in Edebug." + :type 'boolean + :group 'edebug) + +(defcustom edebug-unwrap-results nil "*Non-nil if Edebug should unwrap results of expressions. This is useful when debugging macros where the results of expressions are instrumented expressions. But don't do this when results might be -circular or an infinite loop will result.") - -(defvar edebug-on-error t +circular or an infinite loop will result." + :type 'boolean + :group 'edebug) + +(defcustom edebug-on-error t "*Value bound to `debug-on-error' while Edebug is active. If `debug-on-error' is non-nil, that value is still used. @@ -237,14 +276,20 @@ these errors are signaled from Lisp code whether or not the signal is handled by a `condition-case'. This option is useful for debugging signals that *are* handled since they would otherwise be missed. -After execution is resumed, the error is signaled again.") - -(defvar edebug-on-quit t - "*Value bound to `debug-on-quit' while Edebug is active.") - -(defvar edebug-global-break-condition nil +After execution is resumed, the error is signaled again." + :type '(choice boolean (repeat string)) + :group 'edebug) + +(defcustom edebug-on-quit t + "*Value bound to `debug-on-quit' while Edebug is active." + :type 'boolean + :group 'edebug) + +(defcustom edebug-global-break-condition nil "*If non-nil, an expression to test for at every stop point. -If the result is non-nil, then break. Errors are ignored.") +If the result is non-nil, then break. Errors are ignored." + :type 'sexp + :group 'edebug) ;;; Form spec utilities. diff -r 9fa0ed8da0b1 -r f967f12c8ec8 lisp/lpr.el --- a/lisp/lpr.el Sat Apr 12 04:15:03 1997 +0000 +++ b/lisp/lpr.el Sat Apr 12 08:35:41 1997 +0000 @@ -30,40 +30,59 @@ ;;; Code: +(defgroup lpr nil + "Print Emacs buffer on line printer" + :group 'wp) + + ;;;###autoload -(defvar lpr-switches nil +(defcustom lpr-switches nil "*List of strings to pass as extra options for the printer program. -See `lpr-command'.") +See `lpr-command'." + :type '(repeat (string :tag "Argument")) + :group 'lpr) -(defvar lpr-add-switches (eq system-type 'berkeley-unix) +(defcustom lpr-add-switches (eq system-type 'berkeley-unix) "*Non-nil means construct -T and -J options for the printer program. These are made assuming that the program is `lpr'; if you are using some other incompatible printer program, -this variable should be nil.") +this variable should be nil." + :type 'boolean + :group 'lpr) ;;;###autoload -(defvar lpr-command +(defcustom lpr-command (if (memq system-type '(usg-unix-v dgux hpux irix)) "lp" "lpr") - "*Name of program for printing a file.") + "*Name of program for printing a file." + :type 'string + :group 'lpr) ;; Default is nil, because that enables us to use pr -f ;; which is more reliable than pr with no args, which is what lpr -p does. -(defvar lpr-headers-switches nil +(defcustom lpr-headers-switches nil "*List of strings of options to request page headings in the printer program. If nil, we run `lpr-page-header-program' to make page headings -and print the result.") +and print the result." + :type '(repeat (string :tag "Argument")) + :group 'lpr) -(defvar print-region-function nil +(defcustom print-region-function nil "Function to call to print the region on a printer. -See definition of `print-region-1' for calling conventions.") +See definition of `print-region-1' for calling conventions." + :type 'function + :group 'lpr) -(defvar lpr-page-header-program "pr" - "*Name of program for adding page headers to a file.") +(defcustom lpr-page-header-program "pr" + "*Name of program for adding page headers to a file." + :type 'string + :group 'lpr) -(defvar lpr-page-header-switches '("-f") +(defcustom lpr-page-header-switches '("-f") "*List of strings to use as options for the page-header-generating program. -The variable `lpr-page-header-program' specifies the program to use.") +The variable `lpr-page-header-program' specifies the program to use." + :type '(repeat string) + :group 'lpr) ;;;###autoload (defun lpr-buffer () diff -r 9fa0ed8da0b1 -r f967f12c8ec8 lisp/progmodes/prolog.el --- a/lisp/progmodes/prolog.el Sat Apr 12 04:15:03 1997 +0000 +++ b/lisp/progmodes/prolog.el Sat Apr 12 08:35:41 1997 +0000 @@ -33,21 +33,37 @@ (defvar prolog-mode-syntax-table nil) (defvar prolog-mode-abbrev-table nil) (defvar prolog-mode-map nil) + +(defgroup prolog nil + "Major mode for editing and running Prolog under Emacs" + :group 'languages) + -(defvar prolog-program-name "prolog" - "*Program name for invoking an inferior Prolog with `run-prolog'.") +(defcustom prolog-program-name "prolog" + "*Program name for invoking an inferior Prolog with `run-prolog'." + :type 'string + :group 'prolog) -(defvar prolog-consult-string "reconsult(user).\n" - "*(Re)Consult mode (for C-Prolog and Quintus Prolog). ") +(defcustom prolog-consult-string "reconsult(user).\n" + "*(Re)Consult mode (for C-Prolog and Quintus Prolog). " + :type 'string + :group 'prolog) -(defvar prolog-compile-string "compile(user).\n" - "*Compile mode (for Quintus Prolog).") +(defcustom prolog-compile-string "compile(user).\n" + "*Compile mode (for Quintus Prolog)." + :type 'string + :group 'prolog) -(defvar prolog-eof-string "end_of_file.\n" +(defcustom prolog-eof-string "end_of_file.\n" "*String that represents end of file for prolog. -nil means send actual operating system end of file.") +nil means send actual operating system end of file." + :type 'string + :group 'prolog) -(defvar prolog-indent-width 4) +(defcustom prolog-indent-width 4 + "Level of indentation in Prolog buffers." + :type 'integer + :group 'prolog) (if prolog-mode-syntax-table () diff -r 9fa0ed8da0b1 -r f967f12c8ec8 lisp/rcompile.el --- a/lisp/rcompile.el Sat Apr 12 04:15:03 1997 +0000 +++ b/lisp/rcompile.el Sat Apr 12 08:35:41 1997 +0000 @@ -5,7 +5,6 @@ ;; Author: Albert ;; Maintainer: FSF ;; Created: 1993 Oct 6 -;; Version: 1.1 ;; Keywords: tools, processes ;; This file is part of GNU Emacs. @@ -70,25 +69,41 @@ ;;;; user defined variables -(defvar remote-compile-host nil - "*Host for remote compilations.") +(defgroup remote-compile nil + "Run a compilation on a remote machine" + :group 'processes + :group 'tools) + -(defvar remote-compile-user nil +(defcustom remote-compile-host nil + "*Host for remote compilations." + :type '(choice string (const nil)) + :group 'remote-compile) + +(defcustom remote-compile-user nil "User for remote compilations. -nil means use the value returned by \\[user-login-name].") +nil means use the value returned by \\[user-login-name]." + :type '(choice string (const nil)) + :group 'remote-compile) -(defvar remote-compile-run-before nil +(defcustom remote-compile-run-before nil "*Command to run before compilation. This can be used for setting up environment variables, since rsh does not invoke the shell as a login shell and files like .login \(tcsh\) and .bash_profile \(bash\) are not run. -nil means run no commands.") +nil means run no commands." + :type '(choice string (const nil)) + :group 'remote-compile) -(defvar remote-compile-prompt-for-host nil - "*Non-nil means prompt for host if not available from filename.") +(defcustom remote-compile-prompt-for-host nil + "*Non-nil means prompt for host if not available from filename." + :type 'boolean + :group 'remote-compile) -(defvar remote-compile-prompt-for-user nil - "*Non-nil means prompt for user if not available from filename.") +(defcustom remote-compile-prompt-for-user nil + "*Non-nil means prompt for user if not available from filename." + :type 'boolean + :group 'remote-compile) ;;;; internal variables diff -r 9fa0ed8da0b1 -r f967f12c8ec8 lisp/uniquify.el --- a/lisp/uniquify.el Sat Apr 12 04:15:03 1997 +0000 +++ b/lisp/uniquify.el Sat Apr 12 08:35:41 1997 +0000 @@ -84,7 +84,12 @@ ;;; User-visible variables -(defvar uniquify-buffer-name-style 'post-forward +(defgroup uniquify nil + "Unique buffer names dependent on file name" + :group 'applications) + + +(defcustom uniquify-buffer-name-style 'post-forward "*If non-nil, buffer names are uniquified with parts of directory name. The value determines the buffer name style and is one of `forward', `reverse', `post-forward' (the default), or `post-forward-angle-brackets'. @@ -94,33 +99,49 @@ reverse name\\mumble\\bar name\\mumble\\quux post-forward name|bar/mumble name|quux/mumble post-forward-angle-brackets name name - nil name name<2>") + nil name name<2>" + :type '(radio (const forward) + (const reverse) + (const post-forward) + (const podt-forward-angle-brackets) + (const nil)) + :group 'uniquify) -(defvar uniquify-after-kill-buffer-p nil +(defcustom uniquify-after-kill-buffer-p nil "*If non-nil, rerationalize buffer names after a buffer has been killed. This can be dangerous if Emacs Lisp code is keeping track of buffers by their -names (rather than keeping pointers to the buffers themselves).") +names (rather than keeping pointers to the buffers themselves)." + :type 'boolean + :group 'uniquify) -(defconst uniquify-ask-about-buffer-names-p nil +(defcustom uniquify-ask-about-buffer-names-p nil "*If non-nil, permit user to choose names for buffers with same base file. If the user chooses to name a buffer, uniquification is preempted and no -other buffer names are changed.") +other buffer names are changed." + :type 'boolean + :group 'uniquify) -(defvar uniquify-min-dir-content 0 - "*Minimum parts of directory name included in buffer name.") +(defcustom uniquify-min-dir-content 0 + "*Minimum parts of directory name included in buffer name." + :type 'integer + :group 'uniquify) -(defvar uniquify-separator nil +(defcustom uniquify-separator nil "*String separator for buffer name components. When `uniquify-buffer-name-style' is `post-forward', separates base file name from directory part in buffer names (default \"|\"). When `uniquify-buffer-name-style' is `reverse', separates all -file name components (default \"\\\").") +file name components (default \"\\\")." + :type '(choice (const nil) string) + :group 'uniquify) -(defvar uniquify-trailing-separator-p nil +(defcustom uniquify-trailing-separator-p nil "*If non-nil, add a file name separator to dired buffer names. If `uniquify-buffer-name-style' is `forward', add the separator at the end; if it is `reverse', add the separator at the beginning; otherwise, this -variable is ignored.") +variable is ignored." + :type 'boolean + :group 'uniquify) ;;; Utilities