changeset 32199:883b83d07a24

(define-derived-mode): Tweak generated docstring parts.
author Miles Bader <miles@gnu.org>
date Fri, 06 Oct 2000 05:28:33 +0000
parents 255bf3146d5e
children dfe3d0e80f84
files lisp/emacs-lisp/easy-mmode.el
diffstat 1 files changed, 7 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/emacs-lisp/easy-mmode.el	Fri Oct 06 04:58:36 2000 +0000
+++ b/lisp/emacs-lisp/easy-mmode.el	Fri Oct 06 05:28:33 2000 +0000
@@ -417,18 +417,20 @@
       ;; Make sure the docstring mentions the mode's hook
       (setq docstring
 	    (concat docstring
-		    (unless (eq parent 'fundamental-mode)
+		    (if (eq parent 'fundamental-mode)
+			"\n\nThis mode "
 		      (concat
-		       "\nAdditionally to any hooks its parent mode "
+		       "\n\nIn addition to any hooks its parent mode "
 		       (if (string-match (regexp-quote (format "`%s'" parent))
 					 docstring) nil
 			 (format "`%s' " parent))
-		       "might have run),"))
-		    (format "\nThis mode runs `%s' just before exiting." hook))))
+		       "might have run,\nthis mode "))
+		    (format "runs the hook `%s'" hook)
+		    ", as the final step\nduring initialization.")))
 
     (unless (string-match "\\\\[{[]" docstring)
       ;; And don't forget to put the mode's keymap
-      (setq docstring (concat docstring "\n\\{" (symbol-name map) "}")))
+      (setq docstring (concat docstring "\n\n\\{" (symbol-name map) "}")))
 
     `(progn
        (defvar ,map (make-sparse-keymap))