comparison lisp/modes/enriched.el @ 134:34a5b81f86ba r20-2b1

Import from CVS: tag r20-2b1
author cvs
date Mon, 13 Aug 2007 09:30:11 +0200
parents ac2d302a0011
children e45d5e7c476e
comparison
equal deleted inserted replaced
133:b27e67717092 134:34a5b81f86ba
53 53
54 ;;; 54 ;;;
55 ;;; Variables controlling the display 55 ;;; Variables controlling the display
56 ;;; 56 ;;;
57 57
58 (defvar enriched-verbose t 58 (defgroup enriched nil
59 "*If non-nil, give status messages when reading and writing files.") 59 "Read and save files in text/enriched format"
60 60 :group 'wp)
61 (defvar enriched-default-right-margin 10 61
62
63 (defcustom enriched-verbose t
64 "*If non-nil, give status messages when reading and writing files."
65 :type 'boolean
66 :group 'enriched)
67
68 (defcustom enriched-default-right-margin 10
62 "*Default amount of space to leave on the right edge of the screen. 69 "*Default amount of space to leave on the right edge of the screen.
63 This can be increased inside text by changing the 'right-margin text property. 70 This can be increased inside text by changing the 'right-margin text property.
64 Measured in character widths. If the screen is narrower than this, it is 71 Measured in character widths. If the screen is narrower than this, it is
65 assumed to be 0.") 72 assumed to be 0."
66 73 :type 'integer
67 (defvar enriched-fill-after-visiting t 74 :group 'enriched)
75
76 (defcustom enriched-fill-after-visiting t
68 "If t, fills paragraphs when reading in enriched documents. 77 "If t, fills paragraphs when reading in enriched documents.
69 If nil, only fills when you explicitly request it. If the value is 'ask, then 78 If nil, only fills when you explicitly request it. If the value is 'ask, then
70 it will query you whether to fill. 79 it will query you whether to fill.
71 Filling is never done if the current text-width is the same as the value 80 Filling is never done if the current text-width is the same as the value
72 stored in the file.") 81 stored in the file."
82 :type '(choice (const nil) (const t) (const ask))
83 :group 'enriched)
73 84
74 ;;; 85 ;;;
75 ;;; Set up faces & display table 86 ;;; Set up faces & display table
76 ;;; 87 ;;;
77 88
154 (if (not (assq 'enriched-mode minor-mode-alist)) 165 (if (not (assq 'enriched-mode minor-mode-alist))
155 (setq minor-mode-alist 166 (setq minor-mode-alist
156 (cons '(enriched-mode " Enriched") 167 (cons '(enriched-mode " Enriched")
157 minor-mode-alist))) 168 minor-mode-alist)))
158 169
159 (defvar enriched-mode-hook nil 170 (defcustom enriched-mode-hook nil
160 "Functions to run when entering Enriched mode. 171 "Functions to run when entering Enriched mode.
161 If you set variables in this hook, you should arrange for them to be restored 172 If you set variables in this hook, you should arrange for them to be restored
162 to their old values if you leave Enriched mode. One way to do this is to add 173 to their old values if you leave Enriched mode. One way to do this is to add
163 them and their old values to `enriched-old-bindings'.") 174 them and their old values to `enriched-old-bindings'."
175 :type 'hook
176 :group 'enriched)
164 177
165 (defvar enriched-old-bindings nil 178 (defvar enriched-old-bindings nil
166 "Store old variable values that we change when entering mode. 179 "Store old variable values that we change when entering mode.
167 The value is a list of \(VAR VALUE VAR VALUE...).") 180 The value is a list of \(VAR VALUE VAR VALUE...).")
168 (make-variable-buffer-local 'enriched-old-bindings) 181 (make-variable-buffer-local 'enriched-old-bindings)