changeset 20962:54413501e4a9

Customized.
author Stephen Eglen <stephen@gnu.org>
date Sun, 22 Feb 1998 22:01:28 +0000
parents 79530a618cd3
children 0d56074cec59
files lisp/emacs-lisp/find-func.el lisp/emulation/crisp.el lisp/mail/mail-extr.el lisp/mail/mail-hist.el lisp/mail/sendmail.el lisp/mail/uce.el
diffstat 6 files changed, 190 insertions(+), 81 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/emacs-lisp/find-func.el	Sun Feb 22 20:03:39 1998 +0000
+++ b/lisp/emacs-lisp/find-func.el	Sun Feb 22 22:01:28 1998 +0000
@@ -57,18 +57,26 @@
 ;;;; Code:
 
 ;;; User variables:
+(defgroup find-function nil
+  "Find the definition of the elisp function near point."
+  :prefix "find-function"
+  :group 'lisp)
 
-(defvar find-function-function 'function-at-point
+(defcustom find-function-function 'function-at-point
   "*The function used by `find-function' to select the function near
 point.
 
-For example `function-at-point' or `function-called-at-point'.")
+For example `function-at-point' or `function-called-at-point'."
+  :type 'function
+  :group 'find-function)
 
-(defvar find-function-source-path nil
+(defcustom find-function-source-path nil
   "The default list of directories where find-function searches.
 
 If this variable is `nil' then find-function searches `load-path' by
-default.")
+default."
+  :type '(repeat directory)
+  :group 'find-function)
 
 
 ;;; Functions:
--- a/lisp/emulation/crisp.el	Sun Feb 22 20:03:39 1998 +0000
+++ b/lisp/emulation/crisp.el	Sun Feb 22 22:01:28 1998 +0000
@@ -51,44 +51,59 @@
 
 ;; All these overrides should go *before* the (require 'crisp) statement.
 
+(defgroup crisp nil
+  "Emulator for CRiSP and Brief key bindings."
+  :prefix "crisp-"
+  :group 'emulations)
+
 ;; local variables
 
 (defvar crisp-mode-map (copy-keymap (current-global-map))
   "Local keymap for CRiSP emulation mode.
 All the emulation bindings are done here instead of globally.")
 
-(defvar crisp-mode-modeline-string " *CRiSP*"
-  "String to display in the modeline when CRiSP emulation mode is enabled.")
+(defcustom crisp-mode-modeline-string " *CRiSP*"
+  "String to display in the modeline when CRiSP emulation mode is enabled."
+  :type 'string
+  :group 'crisp)
 
 (defvar crisp-mode-original-keymap (copy-keymap (current-global-map))
   "The original keymap before CRiSP emulation mode remaps anything.
 This keymap is restored when CRiSP emulation mode is disabled.")
 
-(defvar crisp-mode-enabled nil
+(defcustom crisp-mode-enabled nil
   "Track status of CRiSP emulation mode.
 A value of nil means CRiSP mode is not enabled.  A value of t
-indicates CRiSP mode is enabled.")
+indicates CRiSP mode is enabled."
+  :type 'boolean
+  :group 'crisp)
 
-(defvar crisp-override-meta-x t
+(defcustom crisp-override-meta-x t
   "Controls overriding the normal Emacs M-x key binding in the CRiSP emulator.
 Normally the CRiSP emulator rebinds M-x to save-buffers-exit-emacs
 and provides the usual M-x functionality on the F10 key.
 
 If this variable is nil when you start the CRiSP emulator, it
-does not alter the binding of M-x.")
+does not alter the binding of M-x."
+  :type 'boolean
+  :group 'crisp)
 
-(defvar crisp-load-scroll-all t
+(defcustom crisp-load-scroll-all t
   "Controls loading of the Scroll All mode in the CRiSP emulator.
 Its Default behavior is to load and enable the Scroll All minor mode
 package when enabling the CRiSP emulator.
 
 If this variable is nil when you start the CRiSP emulator, it
-does not load Scroll All.")
+does not load Scroll All."
+  :type 'boolean
+  :group 'crisp)
 
-(defvar crisp-load-hook nil
-  "Hooks to run after loadint the CRiSP emulator package.")
+(defcustom crisp-load-hook nil
+  "Hooks to run after loadint the CRiSP emulator package."
+  :type 'hook
+  :group 'crisp)
 
-(defvar crisp-version "crisp.el release 1.1/$Revision: 1.5 $"
+(defvar crisp-version "crisp.el release 1.1/$Revision: 1.6 $"
   "The release number and RCS version for the CRiSP emulator.")
 
 (defvar crisp-last-last-command nil
--- a/lisp/mail/mail-extr.el	Sun Feb 22 20:03:39 1998 +0000
+++ b/lisp/mail/mail-extr.el	Sun Feb 22 22:01:28 1998 +0000
@@ -208,36 +208,51 @@
 ;;; Code:
 
 
+(defgroup mail-extr nil
+  "Extract full name and address from RFC 822 mail header."
+  :prefix "mail-extr-"
+  :group 'mail)
+
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ;;
 ;; User configuration variable definitions.
 ;;
 
-(defvar mail-extr-guess-middle-initial nil
+(defcustom mail-extr-guess-middle-initial nil
   "*Whether to try to guess middle initial from mail address.
 If true, then when we see an address like \"John Smith <jqs@host.com>\"
-we will assume that \"John Q. Smith\" is the fellow's name.")
+we will assume that \"John Q. Smith\" is the fellow's name."
+  :type 'boolean
+  :group 'mail-extr)
 
-(defvar mail-extr-ignore-single-names t
+(defcustom mail-extr-ignore-single-names t
   "*Whether to ignore a name that is just a single word.
 If true, then when we see an address like \"Idiot <dumb@stupid.com>\"
-we will act as though we couldn't find a full name in the address.")
+we will act as though we couldn't find a full name in the address."
+  :type 'boolean
+  :group 'mail-extr)
 
 ;; Matches a leading title that is not part of the name (does not
 ;; contribute to uniquely identifying the person).
-(defvar mail-extr-full-name-prefixes
+(defcustom mail-extr-full-name-prefixes
   (purecopy
    "\\(Prof\\|D[Rr]\\|Mrs?\\|Rev\\|Rabbi\\|SysOp\\|LCDR\\)\\.?[ \t\n]")
   "*Matches prefixes to the full name that identify a person's position.
 These are stripped from the full name because they do not contribute to
-uniquely identifying the person.")
+uniquely identifying the person."
+  :type 'regexp
+  :group 'mail-extr)
 
-(defvar mail-extr-@-binds-tighter-than-! nil
-  "*Whether the local mail transport agent looks at ! before @.")
+(defcustom mail-extr-@-binds-tighter-than-! nil
+  "*Whether the local mail transport agent looks at ! before @."
+  :type 'boolean
+  :group 'mail-extr)
 
-(defvar mail-extr-mangle-uucp nil
+(defcustom mail-extr-mangle-uucp nil
   "*Whether to throw away information in UUCP addresses
-by translating things like \"foo!bar!baz@host\" into \"baz@bar.UUCP\".")
+by translating things like \"foo!bar!baz@host\" into \"baz@bar.UUCP\"."
+  :type 'boolean
+  :group 'mail-extr)
 
 ;;----------------------------------------------------------------------
 ;; what orderings are meaningful?????
--- a/lisp/mail/mail-hist.el	Sun Feb 22 20:03:39 1998 +0000
+++ b/lisp/mail/mail-hist.el	Sun Feb 22 22:01:28 1998 +0000
@@ -56,6 +56,11 @@
 ;;; Code:
 (require 'ring)
 
+(defgroup mail-hist nil
+  "Headers and message body history for outgoing mail."
+  :prefix "mail-hist-"
+  :group 'mail)
+
 ;;;###autoload
 (defun mail-hist-define-keys ()
   "Define keys for accessing mail header history.  For use in hooks."
@@ -72,13 +77,17 @@
 Used for knowing which history list to look in when the user asks for
 previous/next input.")
 
-(defvar mail-hist-history-size (or kill-ring-max 1729)
+(defcustom mail-hist-history-size (or kill-ring-max 1729)
   "*The maximum number of elements in a mail field's history.
-Oldest elements are dumped first.")
+Oldest elements are dumped first."
+  :type 'integer
+  :group 'mail-hist)
 
 ;;;###autoload
-(defvar mail-hist-keep-history t
-  "*Non-nil means keep a history for headers and text of outgoing mail.")
+(defcustom mail-hist-keep-history t
+  "*Non-nil means keep a history for headers and text of outgoing mail."
+  :type 'boolean
+  :group 'mail-hist)
 
 ;; For handling repeated history requests
 (defvar mail-hist-access-count 0)
@@ -182,9 +191,11 @@
   (setq header (downcase header))
   (cdr (assoc header mail-hist-header-ring-alist)))
 
-(defvar mail-hist-text-size-limit nil
+(defcustom mail-hist-text-size-limit nil
   "*Don't store any header or body with more than this many characters.
-If the value is nil, that means no limit on text size.")
+If the value is nil, that means no limit on text size."
+  :type '(choice (const nil) integer)
+  :group 'mail-hist)
 
 (defun mail-hist-text-too-long-p (text)
   "Return t if TEXT does not exceed mail-hist's size limit.
--- a/lisp/mail/sendmail.el	Sun Feb 22 20:03:39 1998 +0000
+++ b/lisp/mail/sendmail.el	Sun Feb 22 22:01:28 1998 +0000
@@ -28,9 +28,13 @@
 ;; documented in the Emacs user's manual.
 
 ;;; Code:
+(defgroup sendmail nil
+  "Mail sending commands for Emacs."
+  :prefix "mail-"
+  :group 'mail)
 
 ;;;###autoload
-(defvar mail-from-style 'angles "\
+(defcustom mail-from-style 'angles "\
 *Specifies how \"From:\" fields look.
 
 If `nil', they contain just the return address like:
@@ -38,22 +42,30 @@
 If `parens', they look like:
 	king@grassland.com (Elvis Parsley)
 If `angles', they look like:
-	Elvis Parsley <king@grassland.com>")
+	Elvis Parsley <king@grassland.com>"
+  :type '(choice (const nil) (const parens) (const angles))
+  :group 'sendmail)
 
 ;;;###autoload
-(defvar mail-self-blind nil "\
+(defcustom mail-self-blind nil "\
 *Non-nil means insert BCC to self in messages to be sent.
 This is done when the message is initialized,
-so you can remove or alter the BCC field to override the default.")
+so you can remove or alter the BCC field to override the default."
+  :type 'boolean
+  :group 'sendmail)
 
 ;;;###autoload
-(defvar mail-interactive nil "\
+(defcustom mail-interactive nil "\
 *Non-nil means when sending a message wait for and display errors.
-nil means let mailer mail back a message to report errors.")
+nil means let mailer mail back a message to report errors."
+  :type 'boolean
+  :group 'sendmail)
 
 ;;;###autoload
-(defvar mail-yank-ignored-headers "^via:\\|^mail-from:\\|^origin:\\|^status:\\|^remailed\\|^received:\\|^message-id:\\|^summary-line:\\|^to:\\|^subject:\\|^in-reply-to:\\|^return-path:" "\
-*Delete these headers from old message when it's inserted in a reply.")
+(defcustom mail-yank-ignored-headers "^via:\\|^mail-from:\\|^origin:\\|^status:\\|^remailed\\|^received:\\|^message-id:\\|^summary-line:\\|^to:\\|^subject:\\|^in-reply-to:\\|^return-path:" "\
+*Delete these headers from old message when it's inserted in a reply."
+  :type 'regexp
+  :group 'sendmail)
 
 ;; Useful to set in site-init.el
 ;;;###autoload
@@ -63,8 +75,10 @@
 match the variable `mail-header-separator'.")
 
 ;;;###autoload
-(defvar mail-header-separator "--text follows this line--" "\
-*Line used to separate headers from text in messages being composed.")
+(defcustom mail-header-separator "--text follows this line--" "\
+*Line used to separate headers from text in messages being composed."
+  :type 'string
+  :group 'sendmail)
 
 ;; Set up mail-header-separator for use as a category text property.
 (put 'mail-header-separator 'rear-nonsticky '(category))
@@ -76,33 +90,43 @@
 ;;;(put 'mail-header-separator 'read-only t)
 
 ;;;###autoload
-(defvar mail-archive-file-name nil "\
+(defcustom mail-archive-file-name nil "\
 *Name of file to write all outgoing messages in, or nil for none.
-This can be an inbox file or an Rmail file.")
+This can be an inbox file or an Rmail file."
+  :type '(choice file (const nil))
+  :group 'sendmail)
 
 ;;;###autoload
-(defvar mail-default-reply-to nil
+(defcustom mail-default-reply-to nil
   "*Address to insert as default Reply-to field of outgoing messages.
 If nil, it will be initialized from the REPLYTO environment variable
-when you first send mail.")
+when you first send mail."
+  :type '(choice (const nil) string)
+  :group 'sendmail)
 
 ;;;###autoload
-(defvar mail-alias-file nil
+(defcustom mail-alias-file nil
   "*If non-nil, the name of a file to use instead of `/usr/lib/aliases'.
 This file defines aliases to be expanded by the mailer; this is a different
 feature from that of defining aliases in `.mailrc' to be expanded in Emacs.
-This variable has no effect unless your system uses sendmail as its mailer.")
+This variable has no effect unless your system uses sendmail as its mailer."
+  :type '(choice (const nil) file)
+  :group 'sendmail)
 
 ;;;###autoload
-(defvar mail-personal-alias-file "~/.mailrc"
+(defcustom mail-personal-alias-file "~/.mailrc"
   "*If non-nil, the name of the user's personal mail alias file.
 This file typically should be in same format as the `.mailrc' file used by
 the `Mail' or `mailx' program.
-This file need not actually exist.")
+This file need not actually exist."
+  :type '(choice (const nil) file)
+  :group 'sendmail)
 
-(defvar mail-setup-hook nil
+(defcustom mail-setup-hook nil
   "Normal hook, run each time a new outgoing mail message is initialized.
-The function `mail-setup' runs this hook.")
+The function `mail-setup' runs this hook."
+  :type 'hook
+  :group 'sendmail)
 
 (defvar mail-aliases t
   "Alist of mail address aliases,
@@ -115,12 +139,17 @@
 (defvar mail-alias-modtime nil
   "The modification time of your mail alias file when it was last examined.")
 
-(defvar mail-yank-prefix nil
+(defcustom mail-yank-prefix nil
   "*Prefix insert on lines of yanked message being replied to.
-nil means use indentation.")
-(defvar mail-indentation-spaces 3
+nil means use indentation."
+  :type '(choice (const nil) string)
+  :group 'sendmail)
+
+(defcustom mail-indentation-spaces 3
   "*Number of spaces to insert at the beginning of each cited line.
-Used by `mail-yank-original' via `mail-indent-citation'.")
+Used by `mail-yank-original' via `mail-indent-citation'."
+  :type 'integer
+  :group 'sendmail)
 (defvar mail-yank-hooks nil
   "Obsolete hook for modifying a citation just inserted in the mail buffer.
 Each hook function can find the citation between (point) and (mark t).
@@ -130,14 +159,16 @@
 This is a normal hook, misnamed for historical reasons.
 It is semi-obsolete and mail agents should no longer use it.")
 
-(defvar mail-citation-hook nil
+(defcustom mail-citation-hook nil
   "*Hook for modifying a citation just inserted in the mail buffer.
 Each hook function can find the citation between (point) and (mark t).
 And each hook function should leave point and mark around the citation
 text as modified.
 
 If this hook is entirely empty (nil), a default action is taken
-instead of no action.")
+instead of no action."
+  :type 'hook
+  :group 'sendmail)
 
 (defvar mail-abbrevs-loaded nil)
 (defvar mail-mode-map nil)
@@ -154,12 +185,16 @@
   nil)
 
 ;;;###autoload
-(defvar mail-signature nil
+(defcustom mail-signature nil
   "*Text inserted at end of mail buffer when a message is initialized.
-If t, it means to insert the contents of the file `mail-signature-file'.")
+If t, it means to insert the contents of the file `mail-signature-file'."
+  :type '(choice (const nil) (const t) string)
+  :group 'sendmail)
 
-(defvar mail-signature-file "~/.signature"
-  "*File containing the text inserted at end of mail buffer.")
+(defcustom mail-signature-file "~/.signature"
+  "*File containing the text inserted at end of mail buffer."
+  :type 'file
+  :group 'sendmail)
 
 (defvar mail-reply-action nil)
 (defvar mail-send-actions nil
@@ -167,25 +202,31 @@
 (put 'mail-reply-action 'permanent-local t)
 (put 'mail-send-actions 'permanent-local t)
 
-(defvar mail-default-headers nil
+(defcustom mail-default-headers nil
   "*A string containing header lines, to be inserted in outgoing messages.
 It is inserted before you edit the message,
-so you can edit or delete these lines.")
+so you can edit or delete these lines."
+  :type '(choice (const nil) string)
+  :group 'sendmail)
 
-(defvar mail-bury-selects-summary t
+(defcustom mail-bury-selects-summary t
   "*If non-nil, try to show RMAIL summary buffer after returning from mail.
 The functions \\[mail-send-on-exit] or \\[mail-dont-send] select
 the RMAIL summary buffer before returning, if it exists and this variable
-is non-nil.")
+is non-nil."
+  :type 'boolean
+  :group 'sendmail)
 
 ;; I find that this happens so often, for innocent reasons,
 ;; that it is not acceptable to bother the user about it -- rms.
-(defvar mail-send-nonascii t
+(defcustom mail-send-nonascii t
   "*Specify whether to allow sending non-ASCII characters in mail.
 If t, that means do allow it.  nil means don't allow it.
 `query' means ask the user each time.
 Including non-ASCII characters in a mail message can be problematical
-for the recipient, who may not know how to decode them properly.")
+for the recipient, who may not know how to decode them properly."
+  :type '(choice (const t) (const nil) (const query))
+  :group 'sendmail)
 
 ;; Note: could use /usr/ucb/mail instead of sendmail;
 ;; options -t, and -v if not interactive.
@@ -245,8 +286,10 @@
 	      . font-lock-string-face))))
   "Additional expressions to highlight in Mail mode.")
 
-(defvar mail-send-hook nil
-  "Normal hook run before sending mail, in Mail mode.")
+(defcustom mail-send-hook nil
+  "Normal hook run before sending mail, in Mail mode."
+  :type 'hook
+  :group 'sendmail)
 
 (defun sendmail-sync-aliases ()
   (let ((modtime (nth 5 (file-attributes mail-personal-alias-file))))
--- a/lisp/mail/uce.el	Sun Feb 22 20:03:39 1998 +0000
+++ b/lisp/mail/uce.el	Sun Feb 22 22:01:28 1998 +0000
@@ -104,11 +104,18 @@
 (require 'sendmail)
 (require 'rmail)
 
-(defvar uce-setup-hook nil
+(defgroup uce nil
+  "Facilitate reply to unsolicited commercial email."
+  :prefix "uce-"
+  :group 'mail)
+
+(defcustom uce-setup-hook nil
   "Hook to run after UCE rant message is composed.
-This hook is run after mail-setup-hook, which is run as well.")
+This hook is run after mail-setup-hook, which is run as well."
+  :type 'hook
+  :group 'uce)
 
-(defvar uce-message-text 
+(defcustom uce-message-text 
   "Recently, I have received an Unsolicited Commercial E-mail from you.
 I do not like UCE's and I would like to inform you that sending
 unsolicited messages to someone while he or she may have to pay for
@@ -141,27 +148,37 @@
 on beginning of some line from the spamming list.  So, when you set it
 up, it might be a good idea to actually use this feature.
 
-Value nil means insert no text by default, lets you type it in.")
+Value nil means insert no text by default, lets you type it in."
+  :type 'string
+  :group 'uce)
 
-(defvar uce-uce-separator
+(defcustom uce-uce-separator
   "----- original unsolicited commercial email follows -----"
   "Line that will begin quoting of the UCE.
-Value nil means use no separator.")
+Value nil means use no separator."
+  :type '(choice (const nil) string)
+  :group 'uce)
 
-(defvar uce-signature mail-signature
+(defcustom uce-signature mail-signature
 "Text to put as your signature after the note to UCE sender.  
 Value nil means none, t means insert ~/.signature file (if it happens
 to exist), if this variable is a string this string will be inserted
-as your signature.")
+as your signature."
+  :type '(choice (const nil) (const t) string)
+  :group 'uce)
 
-(defvar uce-default-headers
+(defcustom uce-default-headers
   "Errors-To: nobody@localhost\nPrecedence: bulk\n"
   "Additional headers to use when responding to a UCE with \\[uce-reply-to-uce].
-These are mostly meant for headers that prevent delivery errors reporting.")
+These are mostly meant for headers that prevent delivery errors reporting."
+  :type 'string
+  :group 'uce)
 
-(defvar uce-subject-line
+(defcustom uce-subject-line
   "Spam alert: unsolicited commercial e-mail"
-  "Subject of the message that will be sent in response to a UCE.")
+  "Subject of the message that will be sent in response to a UCE."
+  :type 'string
+  :group 'uce)
 
 (defun uce-reply-to-uce (&optional ignored)
   "Send reply to UCE in Rmail.