Content-Type: text/enriched Text-Width: 70
bluewhiteenriched.el: bluewhiteWYSIWYG rich text editing for GNU Emacs
bluewhiteINTRODUCTION Emacs now has the ability to edit enriched text, which is text containing faces, colors, indentation, and other properties. This document is a quick introduction to some of the new features, and is also an example file in the text/enriched format. bluewhiteINSTALLATION and STARTUP Most of the time, you need not do anything to get these features to work. If you visit a file that has been written out in text/enriched format, it will automatically be decoded, Emacs will enter `enriched-mode' while visiting it, and whenever you save it it will be saved in the same format it was read in. If you wish to create a new file, however, you will need to turn on enriched-mode yourself: M-x enriched-mode RET Or, if you get a text/enriched file that Emacs does not automatically recognize and decode, you can tell Emacs to decode it (which also turns on enriched-mode automatically): M-x format-decode-buffer RET text/enriched RET bluewhiteWHAT IS ENCODED Here is the current list of text-properties that are saved; they are discussed in more detail below. Most of these can be added or changed with the "Text Properties" menu, available under the "Edit" item in the menu-bar, or on C-mouse-2 (Control + the middle mouse button). Faces: default, bold, italic, underline, etc. Colors: redDarkSlateGrayanyDarkSlateGrayorangething yellowyourgreen screenblue light bluecanviolet display... Newlines: Which ones are real ("hard") newlines, and which can be changed to fit lines into the margins. Margins: can be indented on the left or right. Justification (whether lines should be flush with the left margin, the right margin, fully justified, centered, or left alone). Excerpts: "For quoted material." Read-only regions. bluewhiteFACES and COLORS You can add faces either with the menu or with M-g. The face is applied to the current region. If you are using `transient-mark-mode' and the region is not active, then the face applies to whatever you type next. Any face can have colors. If this is its lone attribute, the face is put on the color submenus of the "Text Properties" menu. bluewhiteNEWLINES and PARAGRAPHS Text/enriched format distinguishes between hard and soft newlines. Hard newlines are used to separate paragraphs, or items in a list, or anywhere that must be a line break no matter what the margins are. Soft newlines are the ones inserted in order to fit text between the margins. The fill and auto-fill functions insert soft newlines as necessary, but hard newlines are only inserted by direct request, such as using the return key or the C-o (open-line) function. bluewhiteINDENTATION The fill functions also understand margins, which can be set for any region of a document. In addition to the menu items, which increase or decrease the margins, there are two commands for setting the margins absolutely: C-c [ (set-left-margin) and C-c ] (set-right-margin). You can change indentation at any point in a paragraph, which makes it possible to do interesting things like hanging-indents: this paragraph was indented by selecting the region from the second word to the end of the paragraph, and indenting only that part. bluewhiteJUSTIFICATION Several styles of justification are possible, the simplest being unfilled. This means that your lines will be left as you write them. This paragraph is unfilled. The most common (for English) style is FlushLeft. This means lines are aligned at the left margin but left uneven at the right. FlushRight makes each line flush with the right margin instead. This paragraph is FlushRight. FlushBoth regions, which are sometimes called "fully justified" are aligned evenly on both edges, so that the text on the page has a smooth appearance as in a book or newspaper article. Unfortunately this does not look as nice with a fixed-width font as it does in a proportionally-spaced printed document; the extra spaces that are needed on the screen can make it hard to read.
Center Finally, there is center justification. The normal center-paragraph key, M-S, can be used to turn on center justification in enriched-mode. M-j or the "Text Properties" menu also can be used to change justification.
Note that justification can only change at hard newlines, because that is the unit over which filling gets done.
bluewhiteEXCERPTS This is an example of an excerpt. You can use them for quoted parts of other people's email messages and the like. It is just a face, which is the same as the `italic' face by default. bluewhiteTHE FILE FORMAT Enriched-mode documents are saved in an extended version of a format called text/enriched, which is defined as part of the MIME standard. This means that your documents are transportable (even through email) to many other systems. In the future other file formats may be supported as well. Since Emacs adds some non-standard features to the format (colors and read-only regions), not all systems will be able to recreate all of the features of your document, but they will get as close as possible. The MIME standard is defined in Internet RFC 1521; text/enriched is defined in RFC 1563. Details on obtaining these documents via FTP or email may be obtained by sending an email message to rfc-info@isi.edu with the message body: help: ways_to_get_rfcs See also the newsgroup comp.mail.mime. bluewhiteCUSTOMIZATION - The fixed and excerpt faces should be set to your liking. - User-preference variables: default-justification, enriched-verbose. - You can add annotations for your own text properties by making additions to enriched-translations. Note that the standard requires you to name your annotation starting "x-" (as in "x-read-only"). Please send me any such additions that you think might be of general interest so that I can include them in the distribution. bluewhiteTO-DO LIST [Feel free to work on these and send me the results!] + Conform to updated text/enriched spec in RFC 1896. + Be smarter about fixing malformed files. + Make the indentation work more seamlessly and robustly: + Create an aggressive auto-fill function that will keep the paragraph properly filled all the time, without slowing down editing too much. Refill mode is a start at this, but needs improvement. + Refill after yank. [Refill mode does that.] + Make deleting a newline also delete the indentation following it. + Never let point enter indentation?? + Notice and re-fill when window changes widths (optionally). + Deal with the `category' text-property in a smart way. + Interface w/ Gnus, VM, RMAIL. Maybe Info too? (Gnus 5.9 copes with text/enriched incoming mail.) + Support more formats: RTF, HTML... + Use Emacs 21 display features. bluewhiteFinal Notes: This code and documentation is under development. Comments and bug reports are welcome. whiteblueBoris Goldowskylight blue light blue<blue bluewhiteApril 1995; updated August 1997 Copyright (C) 1995, 1997, 2001-2012 Free Software Foundation, Inc. COPYING PERMISSIONS: This document is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see <.