/[emacs]/emacs/lisp/autoinsert.el
ViewVC logotype

Diff of /emacs/lisp/autoinsert.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.38 by jpw, Mon Nov 15 20:46:17 2004 UTC revision 1.39 by monnier, Thu Mar 24 12:42:18 2005 UTC
# Line 1  Line 1 
1  ;;; autoinsert.el --- automatic mode-dependent insertion of text into new files  ;;; autoinsert.el --- automatic mode-dependent insertion of text into new files
2    
3  ;; Copyright (C) 1985, 86, 87, 94, 95, 98, 2000, 03 Free Software Foundation, Inc.  ;; Copyright (C) 1985, 1986, 1987, 1994, 1995, 1998, 2000, 2003, 2005
4    ;;           Free Software Foundation, Inc.
5    
6  ;; Author: Charlie Martin <crm@cs.duke.edu>  ;; Author: Charlie Martin <crm@cs.duke.edu>
7  ;; Adapted-By: Daniel Pfeiffer <occitan@esperanto.org>  ;; Adapted-By: Daniel Pfeiffer <occitan@esperanto.org>
# Line 33  Line 34 
34  ;;  auto-mode-alist.  ;;  auto-mode-alist.
35  ;;  ;;
36  ;;  To use:  ;;  To use:
37  ;;     (add-hook 'find-file-hooks 'auto-insert)  ;;     (add-hook 'find-file-hook 'auto-insert)
38  ;;     setq auto-insert-directory to an appropriate slash-terminated value  ;;     setq auto-insert-directory to an appropriate slash-terminated value
39  ;;  ;;
40  ;;  You can also customize the variable `auto-insert-mode' to load the  ;;  You can also customize the variable `auto-insert-mode' to load the
# Line 67  Insertion is possible when something app Line 68  Insertion is possible when something app
68  `auto-insert-alist'.  When the insertion is marked as unmodified, you can  `auto-insert-alist'.  When the insertion is marked as unmodified, you can
69  save it with  \\[write-file] RET.  save it with  \\[write-file] RET.
70  This variable is used when the function `auto-insert' is called, e.g.  This variable is used when the function `auto-insert' is called, e.g.
71  when you do (add-hook 'find-file-hooks 'auto-insert).  when you do (add-hook 'find-file-hook 'auto-insert).
72  With \\[auto-insert], this is always treated as if it were t."  With \\[auto-insert], this is always treated as if it were t."
73    :type '(choice (const :tag "Insert if possible" t)    :type '(choice (const :tag "Insert if possible" t)
74                   (const :tag "Do nothing" nil)                   (const :tag "Do nothing" nil)
# Line 326  When Auto-insert mode is enabled, when n Line 327  When Auto-insert mode is enabled, when n
327  insert a template for the file depending on the mode of the buffer."  insert a template for the file depending on the mode of the buffer."
328    :global t :group 'auto-insert    :global t :group 'auto-insert
329    (if auto-insert-mode    (if auto-insert-mode
330        (add-hook 'find-file-hooks 'auto-insert)        (add-hook 'find-file-hook 'auto-insert)
331      (remove-hook 'find-file-hooks 'auto-insert)))      (remove-hook 'find-file-hook 'auto-insert)))
332    
333  (provide 'autoinsert)  (provide 'autoinsert)
334    
335  ;;; arch-tag: 5b6630ac-c735-43cf-b097-b78c622af909  ;; arch-tag: 5b6630ac-c735-43cf-b097-b78c622af909
336  ;;; autoinsert.el ends here  ;;; autoinsert.el ends here

Legend:
Removed from v.1.38  
changed lines
  Added in v.1.39

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26