;ELC   
;;; compiled by rms@mole.gnu.ai.mit.edu on Sat Nov 11 00:00:31 1995
;;; from file /home/fsf/rms/e19/lisp/enriched.el
;;; emacs version 19.29.1.1.
;;; bytecomp version FSF 2.10
;;; optimization is on.
;;; this file uses opcodes which do not exist in Emacs 18.

(if (and (boundp 'emacs-version)
	 (or (and (boundp 'epoch::version) epoch::version)
	     (string-lessp emacs-version "19.28.90")))
    (error "`enriched.el' was compiled for Emacs 19.29 or later"))


(byte-code "ÀÁ!ˆ\nƒ\f ÃÄ!ˆÀ‡" [provide enriched window-system require facemenu] 2)
#@67 *If non-nil, give status messages when reading and writing files.
(defvar enriched-verbose t (#$ . -559))
#@238 *Default amount of space to leave on the right edge of the screen.
This can be increased inside text by changing the 'right-margin text property.
Measured in character widths.  If the screen is narrower than this, it is
assumed to be 0.
(defvar enriched-default-right-margin 10 (#$ . -672))
#@267 If t, fills paragraphs when reading in enriched documents.
If nil, only fills when you explicitly request it.  If the value is 'ask, then
it will query you whether to fill.
Filling is never done if the current text-width is the same as the value
stored in the file.
(defvar enriched-fill-after-visiting t (#$ . 970))
(byte-code "ÀÁ!„\" ÂÁ!ˆƒ\" ÄÁÅÆÇÈ #† ÅÉÇÈ #@\"ˆÀÊ!„6 ÂÊ!ˆƒ6 ËÊÌÍ#ˆÎ!†? Ð ÑBÓÔÕ SÖ\"I‡" [internal-find-face fixed make-face window-system set-face-font x-list-fonts "*fixed-medium*" default selected-frame "*fixed*" excerpt make-face-italic nil t copy-sequence standard-display-table make-display-table enriched-display-table current-load-list 12 make-vector frame-width 45] 6)
#@120 Text-properties that usually apply to whole paragraphs.
These are set front-sticky everywhere except at hard newlines.
(defconst enriched-par-props (quote (left-margin right-margin justification)) (#$ . 1683))
#@191 What to insert at the start of a text/enriched file.
If this is a string, it is inserted.  If it is a list, it should be a lambda
expression, which is evaluated to get the string to insert.
(defconst enriched-initial-annotation #[nil "ÀÁÂ \"‡" [format "Content-Type: text/enriched\nText-Width: %d\n\n" enriched-text-width] 3] (#$ . 1900))
#@46 General format of enriched-text annotations.
(defconst enriched-annotation-format "<%s%s>" (#$ . 2245))
#@56 Regular expression matching enriched-text annotations.
(defconst enriched-annotation-regexp "<\\(/\\)?\\([-A-za-z0-9]+\\)>" (#$ . 2355))
#@149 List of definitions of text/enriched annotations.
See `format-annotate-region' and `format-deannotate-region' for the definition
of this structure.
(defconst enriched-translations (quote ((face (bold-italic "bold" "italic") (bold "bold") (italic "italic") (underline "underline") (fixed "fixed") (excerpt "excerpt") (default) (nil enriched-encode-other-face)) (left-margin (4 "indent")) (right-margin (4 "indentright")) (justification (none "nofill") (right "flushright") (left "flushleft") (full "flushboth") (center "center")) (PARAMETER (t "param")) (FUNCTION (enriched-decode-foreground "x-color") (enriched-decode-background "x-bg-color")) (read-only (t "x-read-only")) (unknown (nil format-annotate-value)))) (#$ . 2499))
#@176 Properties that are OK to ignore when saving text/enriched files.
Any property that is neither on this list nor dealt with by
`enriched-translations' will generate a warning.
(defconst enriched-ignore (quote (front-sticky rear-nonsticky hard)) (#$ . 3234))
#@36 True if `enriched-mode' is in use.
(defvar enriched-mode nil (#$ . 3497))
(byte-code "ÀÁ!ˆÁ\nž„ Ã\nBÀ‡" [make-variable-buffer-local enriched-mode minor-mode-alist (enriched-mode " Enriched")] 2)
#@257 Functions to run when entering `enriched-mode'.
If you set variables in this hook, you should arrange for them to be restored
to their old values if enriched-mode is left.  One way to do this is to add
them and their old values to `enriched-old-bindings'.
(defvar enriched-mode-hooks nil (#$ . 3701))
#@111 Store old variable values that we change when entering mode.
The value is a list of (VAR VALUE VAR VALUE...).
(defvar enriched-old-bindings nil (#$ . 4009))
(byte-code "ÀÁ!ˆÂÃ!„\f ÄÃBÀÃ!‡" [make-variable-buffer-local enriched-old-bindings boundp enriched-text-width nil current-load-list] 2)
#@361 Minor mode for editing text/enriched files.
These are files with embedded formatting information in the MIME standard
text/enriched format.
Turning the mode on runs `enriched-mode-hooks'.

More information about enriched-mode is available in the file 
etc/enriched.doc  in the Emacs distribution directory.

Commands:

\<enriched-mode-map>\{enriched-mode-map}
(defalias 'enriched-mode #[(&optional arg) "À Â!ÄX„ ƒ4 „4 ÆÇÈ	\"	\nƒª \n@\nA@Lˆ\nAA‰\n‚ „ª ËÈ	>„G È	B	Ì\fÍÎÏ¯\nÐÍ!ˆÐÎ!ˆÐÏ!ˆÑ\fËÓÔ\"ƒ— @>„Ž @BA‰„} ƒ¥ ØÔ#*ÙÚ!ˆÛ	!ˆÜ )‡" [buffer-modified-p mod prefix-numeric-value arg 0 enriched-mode nil delq text/enriched buffer-file-format enriched-old-bindings t buffer-display-table indent-line-function use-hard-newlines default-text-properties make-local-variable indent-to-left-margin enriched-display-table plist-get front-sticky enriched-par-props p sticky plist-put run-hooks enriched-mode-hooks set-buffer-modified-p force-mode-line-update] 9 (#$ . 4311) "P"])
#@29 Keymap for `enriched-mode'.
(defvar enriched-mode-map nil (#$ . 5347))
(byte-code "„ ÀÁ ‰MˆÂž„ ÂBBÄÅÆ#ˆÄÇÈ#ˆÄÉÈ#ˆÄÊË#ˆÄÌÍ#ˆÄÎÏ#ˆÄÐÑ#ˆÄÒÓ#‡" [enriched-mode-map make-sparse-keymap enriched-mode minor-mode-map-alist define-key "" beginning-of-line-text "" reindent-then-newline-and-indent "\n" "ê" facemenu-justification-menu "Ó" set-justification-center "	" increase-left-margin "\f" set-left-margin "" set-right-margin] 4)
#@378 Apply a function to regions of the buffer based on a text property.
For each contiguous region of the buffer for which the value of PROPERTY is
eq, the FUNCTION will be called.  Optional arguments FROM and TO specify the
region over which to scan.

The specified function receives three arguments: the VALUE of the property in
the region, and the START and END of each region.
(defalias 'enriched-map-property-regions #[(prop func &optional from to) "ŠŒƒ\n e}ˆ	† ebˆ`ÂÃ Ä`\"	Ê	d$‰ƒR Â“ˆ	Ì!#ˆÌ!	Ä\"‚! 	dW…a 	d#.‡" [to from nil make-marker get-text-property prop val marker end begin text-property-not-all func marker-position] 6 (#$ . 5798)])
(put (quote enriched-map-property-regions) (quote lisp-indent-hook) 1)
#@45 Indent and justify each line in the region.
(defalias 'enriched-insert-indentation #[(&optional from to) "ŠŒƒ\n e}ˆ	† ebˆn„ Âyˆm?…1 l„+ Ã jˆÄÅÆÅ#ˆÂyˆ‚ *‡" [to from 1 current-left-margin justify-current-line t nil] 4 (#$ . 6560)])
#@132 The width of unindented text in this window, in characters.
This is the width of the window minus `enriched-default-right-margin'.
(defalias 'enriched-text-width #[nil "† Á ‰Vƒ \nZ‚ \n‰)‡" [enriched-text-width window-width ww enriched-default-right-margin] 3 (#$ . 6802)])
(defalias 'enriched-encode #[(from to) "ƒ ÁÂ!ˆŒ\f}ˆÅ ˆÆ ˆbˆÇÈ!ˆÉÊdÌ%!ˆbˆ;ƒ4 ‚7  cˆÏÐÑ`Ò$ˆƒH ÁÒ!ˆd)‡" [enriched-verbose message "Enriched: encoding document..." from to delete-to-left-margin unjustify-region format-replace-strings (("<" . "<<")) format-insert-annotations format-annotate-region enriched-translations enriched-make-annotation enriched-ignore enriched-initial-annotation enriched-map-property-regions hard #[(v b e) "… 	fÂU… 	bˆÃc‡" [v b 10 "\n"] 2] nil] 7])
#@127 Format an annotation called NAME.
If POSITIVE is non-nil, this is the opening annotation, if nil, this is the
matching close.
(defalias 'enriched-make-annotation #[(name positive) ";ƒ Á\nƒ Ä‚ Å#‡ƒ. @AÁ\nÄ#ÈÉÄ#P*‡Á\nÅ@#‡" [name format enriched-annotation-format positive "" "/" params item mapconcat #[(i) "À	ÂQ‡" ["<param>" i "</param>"] 3]] 5 (#$ . 7583)])
#@119 Generate annotations for random face change.
One annotation each for foreground color, background color, italic, etc.
(defalias 'enriched-encode-other-face #[(old new) "… Á!\n… Á\n!B‡" [old enriched-face-ans new] 3 (#$ . 7966)])
#@37 Return annotations specifying FACE.
(defalias 'enriched-face-ans #[(face) "ÀÁÂ!\"ƒ ÄÂ!ÅÆODC‡ÀÇÂ!\"ƒ& ÈÂ!ÅÆODC‡É!\nË!\fÍÎ\"ÐÃÆ$A\nƒO Ä\nDB\fƒ] È\fDB,‡" [string-match "^fg:" symbol-name face "x-color" 3 nil "^bg:" "x-bg-color" face-foreground fg face-background bg face-font t props format-annotate-single-property-change enriched-translations ans] 5 (#$ . 8205)])
(defalias 'enriched-decode #[(from to) "ƒ ÁÂ!ˆŠŒ\f}ˆbˆÅ ÆÉ ˆbˆÊËÌÆ#ƒB Í ƒ/ ÎÏ!ˆÐÑ”`ÒÆ$ˆÐÑ”`ÓÌ$ˆ‚ ÔdÖ$ˆƒW × U„i ƒi Ù=ƒo ÚÛ!„o Ü ˆ‚| ƒw ÁÝ!ˆÞed\"ˆ*ƒ… ÁÌ!ˆd*‡" [enriched-verbose message "Enriched: decoding document..." from to enriched-get-file-width t use-hard-newlines file-width enriched-remove-header search-forward-regexp "\n\n+" nil current-justification delete-char -1 put-text-property 0 hard front-sticky format-deannotate-region enriched-translations enriched-next-annotation enriched-text-width enriched-fill-after-visiting ask y-or-n-p "Re-fill for current display width? " enriched-insert-indentation "Filling paragraphs..." fill-region] 5])
#@170 Find and return next text/enriched annotation.
Any "<<" strings encountered are converted to "<".
Return value is (begin end name positive-p), or nil if none was found.
(defalias 'enriched-next-annotation #[nil "ÀÁÂÃ#ƒ/ Ä”bˆÅ!„/ Ãuˆ`fÇUƒ$ ÈÃ!ˆ‚  ÉÊË`S\"!ˆ‚  m?…S Ä”\fÄ•Î”Î•{—Ã”?\fF,‡" [search-forward "<" nil 1 0 looking-at enriched-annotation-regexp 60 delete-char message format "Warning: malformed annotation in file at %s" beg end 2 name pos] 4 (#$ . 9282)])
#@47 Look for file width information on this line.
(defalias 'enriched-get-file-width #[nil "ŠÀÁ`Â\\Ã#… Äp!)‡" [search-forward "Text-Width: " 1000 t read] 4 (#$ . 9767)])
#@37 Remove file-format header at point.
(defalias 'enriched-remove-header #[nil "ÀÁ!ƒ `Â•|ˆ‚  ÀÃ!… ÄÅ!‡" [looking-at "^[-A-Za-z]+: .*\n" 0 "^\n" delete-char 1] 2 (#$ . 9940)])
(defalias 'enriched-decode-foreground #[(from to color) "ÀÁ\nP!Ä!„- ƒ Æ!„- ƒ\" ÇÈ\n\"ˆ‚- É!ƒ- ÇÊ\n\"ˆ\fÃF)‡" [intern "fg:" color face internal-find-face window-system facemenu-get-face message "Warning: color \"%s\" is not defined." make-face "Warning: Color \"%s\" can't be displayed." from to] 4])
(defalias 'enriched-decode-background #[(from to color) "ÀÁ\nP!Ä!„- ƒ Æ!„- ƒ\" ÇÈ\n\"ˆ‚- É!ƒ- ÇÊ\n\"ˆ\fÃF)‡" [intern "bg:" color face internal-find-face window-system facemenu-get-face message "Warning: color \"%s\" is not defined." make-face "Warning: Color \"%s\" can't be displayed." from to] 4])
