Make Emacs Muse 3.02.93 (3.03 RC3) available
[muse-el.git] / muse.texi
blobb10f5b8ed1b2b2e76c4a6d2993b956847b7525b5
1 \input texinfo @c -*-texinfo-*-
2 @c %**start of header
3 @setfilename muse.info
4 @settitle Muse
5 @c %**end of header
7 @dircategory Emacs
8 @direntry
9 * Muse: (muse). Authoring and publishing environment for Emacs.
10 @end direntry
12 @syncodeindex fn cp
14 @copying
15 This manual is for Emacs Muse version 3.02.93 (3.03 RC3).
17 Copyright @copyright{} 2004, 2005, 2006 Free Software Foundation, Inc.
19 @quotation
20 Permission is granted to copy, distribute and/or modify this document
21 under the terms of the GNU General Public License.
22 @end quotation
23 @end copying
25 @titlepage
26 @title Muse manual
27 @subtitle an authoring and publishing environment
28 @subtitle for GNU Emacs and XEmacs
30 @c The following two commands
31 @c start the copyright page.
32 @page
33 @vskip 0pt plus 1filll
34 @insertcopying
35 @end titlepage
37 @c So the toc is printed at the start
38 @contents
40 @ifnottex
41 @node Top, Preface, (dir), (dir)
42 @comment  node-name,  next,  previous,  up
43 @top Muse
45 @insertcopying
46 @end ifnottex
48 @menu
49 * Preface::                     About the documentation.
50 * Introduction::                What is Muse?
51 * Obtaining Muse::              How to get Muse releases and development
52                                   changes.
53 * Installation::                Compiling and installing Muse.
54 * Getting Started::             Settings for Muse.
55 * Projects::                    Creating and managing Muse projects.
56 * Keystroke Summary::           Keys used in Muse mode.
57 * Markup Rules::                Rules for using markup.
58 * Publishing Styles::           Publishing various types of documents.
59 * Extending Muse::              Making your own publishing styles.
60 * Getting Help and Reporting Bugs::  
61 * History::                     History of this document.
62 * Contributors::                Contributors to this documentation.
63 * GNU General Public License::  The license for this manual and Muse.
64 * Concept Index::               Search for terms.
66 @detailmenu
67  --- The Detailed Node Listing ---
69 How to Get Muse Releases and Development Changes
71 * Releases::                    Released versions of Muse.
72 * Development::                 Latest unreleased development changes.
74 Rules for Using Markup
76 * Paragraphs::                  Paragraphs: centering and quoting.
77 * Headings::                    Levels of headings.
78 * Directives::                  Directives at the beginning of a
79                                   document.
80 * Emphasizing Text::            Bold, italicized, and underlined text.
81 * Footnotes::                   Making notes to be shown at the end.
82 * Verse::                       Indicating poetic stanzas.
83 * Lists::                       Lists of items.
84 * Tables::                      Generation of data tables.
85 * Explicit Links::              Hyperlinks and email addresses with
86                                   descriptions.
87 * Implicit Links::              Bare URLs, WikiNames, and InterWiki
88                                   links.
89 * Images::                      Publishing and displaying images.
90 * Horizontal Rules and Anchors::  Inserting a horizontal line or anchor.
91 * Embedded Lisp::               Evaluating Emacs Lisp code in documents
92                                   for extensibility.
93 * Comments::                    Lines to omit from published output.
94 * Tag Summary::                 Tags that Muse recognizes.
96 Publishing Various Types of Documents
98 * Blosxom::                     Integrating Muse and pyblosxom.cgi.
99 * Book::                        Publishing entries into a compilation.
100 * DocBook::                     Publishing in DocBook XML form.
101 * HTML::                        Publishing in HTML or XHTML form.
102 * Journal::                     Keeping a journal or blog.
103 * LaTeX::                       Publishing LaTeX documents.
104 * Poem::                        Publish a poem to LaTex or PDF.
105 * Texinfo::                     Publish entries to Texinfo format or PDF.
107 Integrating Muse and pyblosxom.cgi
109 * Blosxom Requirements::        Other tools needed for the Blosxom style.
110 * Blosxom Entries::             Format of a Blosxom entry and automation.
111 * Blosxom Options::             Blosxom styles and options provided.
113 Making your own publishing styles
115 * Common Elements::             Common functionality shared by styles.
116 * Deriving Styles::             Deriving a new style from an existing
117                                   one.
119 Common functionality shared by styles
121 * Markup Functions::            Specifying functions to marking up text.
122 * Markup Regexps::              Markup rules for publishing.
123 * Markup Strings::              Strings specific to a publishing style.
124 * Markup Tags::                 Tag specifications for special markup.
125 * Style Elements::              Parameters used for defining styles.
127 @end detailmenu
128 @end menu
130 @node Preface, Introduction, Top, Top
131 @comment  node-name,  next,  previous,  up
132 @chapter About the documentation
134 This document describes Muse, which was written by John Wiegley
135 and is now maintained by Michael Olson.  Several versions of it are
136 available on-line.
138 @itemize @bullet
139 @item PDF: http://www.mwolson.org/static/doc/muse.pdf
140 @item HTML (single file): http://www.mwolson.org/static/doc/muse.html
141 @item HTML (multiple files): http://www.mwolson.org/static/doc/muse/
142 @end itemize
144 @node Introduction, Obtaining Muse, Preface, Top
145 @comment  node-name,  next,  previous,  up
146 @chapter What is Muse?
148 Emacs Muse is an authoring and publishing environment for Emacs.  It
149 simplifies the process of writing documents and publishing them to
150 various output formats.
152 Muse consists of two main parts: an enhanced text-mode for authoring
153 documents and navigating within Muse projects, and a set of publishing
154 styles for generating different kinds of output.
156 This idea is not in any way new. Numerous systems exist -- even one
157 other for Emacs itself (Bhl Mode). What Muse adds to the picture is a
158 more modular environment, with a rather simple core, in which "styles"
159 are derived from to create new styles. Much of Muse's overall
160 functionality is optional. For example, you can use the publisher
161 without the major-mode, or the mode without doing any publishing; or if
162 you don't load the Texinfo or LaTeX modules, those styles won't be
163 available.
165 The Muse codebase is a departure from emacs-wiki.el version 2.44. The
166 code has been restructured and rewritten, especially its publishing
167 functions. The focus in this revision is on the authoring and publishing
168 aspects, and the "wikiness" has been removed as a default behavior
169 (available in the optional @file{muse-wiki} module). CamelCase words are
170 no longer special by default.
172 @node Obtaining Muse, Installation, Introduction, Top
173 @comment  node-name,  next,  previous,  up
174 @chapter How to Get Muse Releases and Development Changes
176 @menu
177 * Releases::                    Released versions of Muse.
178 * Development::                 Latest unreleased development changes.
179 @end menu
181 @node Releases, Development, Obtaining Muse, Obtaining Muse
182 @comment  node-name,  next,  previous,  up
183 @section Released versions of Muse
185 Choose to install a release if you want to minimize risk.
187 Errors are corrected in development first.  User-visible changes will be
188 announced on the @email{muse-el-discuss@@gna.org} mailing list.
189 @xref{Getting Help and Reporting Bugs}.
191 @cindex releases, Debian package
192 @cindex Debian package for Muse
193 Debian and Ubuntu users can get Muse via apt-get.  The @file{muse-el}
194 package is available both at Michael Olson's APT repository and the
195 official Debian and Ubuntu repositories.  To make use of the former, add
196 the following line to your @file{/etc/apt/sources.list} file and run
197 @code{apt-get install muse}.
199 @example
200 deb http://www.mwolson.org/debian/ ./
201 @end example
203 @cindex releases, from source
204 Alternatively, you can download the latest release from
205 @uref{http://www.mwolson.org/static/dist/muse/} .
207 @node Development,  , Releases, Obtaining Muse
208 @comment  node-name,  next,  previous,  up
209 @section Latest unreleased development changes
210 @cindex development
212 Choose the development version if you want to live on the bleeding edge
213 of Muse development or try out new features before release.
215 @cindex arch revision control system, using
216 The Arch revision control system allows you to retrieve previous
217 versions and select specific features and bug fixes.  If you would like
218 to contribute to Muse development, it is highly recommended that you use
219 Arch, but this is not a requirement.
221 If you are new to Arch, you might find this tutorial helpful:
222 @uref{http://www.mwolson.org/projects/ArchTutorial.html}.
224 Downloading the Muse module with Arch and staying up-to-date involves
225 the following steps.
227 @enumerate
228 @item Install arch
230 @itemize @bullet
231 @item Debian and Ubuntu: @kbd{apt-get install tla}.
232 @item Other distributions: see @uref{http://regexps.srparish.net/www/}.
233 @end itemize
235 @item Register the archive.
236 @example
237 tla register-archive -f http://www.mwolson.org/archives/2005
238 @end example
240 @item Download the Muse package.
241 @example
242 # Download Muse into the @file{muse} directory.
243 tla get mwolson@@gnu.org--2005/muse--main--1.0 muse
244 @end example
246 @item List upstream changes that are missing from your local copy.
247 Do this whenever you want to see whether new changes have been committed
248 to Muse.
250 @example
251 # Change to the source directory you are interested in.
252 cd muse/
254 # Display the summary of changes
255 tla missing --summary
256 @end example
258 @cindex updating Muse with Arch
259 @item Update to the latest version by replaying missing changes.
260 @example
261 cd muse
262 tla replay
263 @end example
265 @end enumerate
267 There are other ways to interact with the Muse archive.
269 @itemize
270 @item Browse arch repository: @uref{http://www.mwolson.org/archives/}
271 @item Latest development snapshot: @uref{http://www.mwolson.org/static/dist/muse-latest.tar.gz}
272 @end itemize
274 The latest development snapshot will be kept up-to-date since it is
275 updated at the same time as the Arch repository.
277 @node Installation, Getting Started, Obtaining Muse, Top
278 @comment  node-name,  next,  previous,  up
279 @chapter Compiling and Installing Muse
281 Muse may be compiled and installed on your machine.
283 @subheading Compilation
285 This is an optional step, since Emacs Lisp source code does not
286 necessarily have to be byte-compiled.  It will yield a speed increase,
287 though.
289 A working copy of Emacs or XEmacs is needed in order to compile the
290 Emacs Muse.  By default, the program that is installed with the name
291 @command{emacs} will be used.
293 If you want to use the @command{xemacs} binary to perform the
294 compilation, you would need to edit @file{Makefile.defs} in the
295 top-level directory as follows.  You can put either a full path to an
296 Emacs or XEmacs binary or just the command name, as long as it is in the
297 @env{PATH}.
299 @example
300 EMACS    = xemacs
301 SITEFLAG = -no-site-file
302 @end example
304 Running @code{make} should compile the Muse source files in the
305 @file{lisp} directory.
307 @subheading Installation
309 Muse may be installed into your file hierarchy by doing the following.
311 Edit the @file{Makefile.defs} file so that @env{ELISPDIR} points to
312 where you want the source and compiled Muse files to be installed and
313 @env{INFODIR} indicates where to put the Muse manual.  Of course, you
314 will want to edit @env{EMACS} and @env{SITEFLAG} as shown in the
315 Compilation section if you are using XEmacs.
317 If you are installing Muse on a Debian or Ubuntu system, you might want
318 to change the value of @env{INSTALLINFO} as specified in
319 @file{Makefile.defs}.
321 If you wish to install Muse to different locations than the defaults
322 specify, edit @file{Makefile.defs} accordingly.
324 Run @code{make} as a normal user.
326 Run @code{make install} as the root user if you have chosen installation
327 locations that require this.
330 @node Getting Started, Projects, Installation, Top
331 @comment  node-name,  next,  previous,  up
332 @chapter Getting Started
333 @cindex settings
335 To use Muse, add the directory containing its files to your
336 @code{load-path} variable, in your @file{.emacs} file.  Then, load in
337 the authoring mode, and the styles you wish to publish to.  An example
338 follows.
340 @lisp
341 (add-to-list 'load-path "<path to Muse>")
343 (require 'muse-mode)     ; load authoring mode
345 (require 'muse-html)     ; load publishing styles I use
346 (require 'muse-latex)
347 (require 'muse-texinfo)
348 (require 'muse-docbook)
349 @end lisp
351 Once loaded, the command @kbd{M-x muse-publish-this-file} will publish
352 an input document to any available style.  If you enable
353 @file{muse-mode} within a buffer, by typing @kbd{M-x muse-mode}, this
354 command will be bound to @kbd{C-c C-t}.
356 If the currently opened file is part of a defined project in
357 @code{muse-project-alist}, it may be published using @kbd{C-c C-p}.
359 You should also type @kbd{M-x customize-group}, and give the name
360 @samp{muse}.  Each of the options has its own documentation.
363 @node Projects, Keystroke Summary, Getting Started, Top
364 @comment  node-name,  next,  previous,  up
365 @chapter Creating and Managing Muse Projects
366 @cindex projects
368 Often you will want to publish all the files within a directory to a
369 particular set of output styles automatically.  To support, Muse
370 allows for the creations of "projects".  Here is a sample project, to
371 be defined in your @file{.emacs} file.
373 @lisp
374 (require 'muse-project)
376 (setq muse-project-alist
377       '(("website"                      ; my various writings
378          ("~/Pages" :default "index")
379          (:base "html" :path "~/public_html")
380          (:base "pdf" :path "~/public_html/pdf"))))
381 @end lisp
383 The above defines a project named "website", whose files are located
384 in the directory @file{~/Pages}.  The default page to visit is
385 @file{index}.  When this project is published, each page will be
386 output as HTML to the directory @file{~/public_html}, and as PDF to
387 the directory @file{~/public_html/pdf}.  Within any project page, you
388 may create a link to other pages using the syntax @samp{[[pagename]]}.
390 By default, Muse expects all project files to have the file extension
391 @file{.muse}. Files without this extension will not be associated with
392 Muse mode and will not be considered part of any project, even if they
393 are within a project directory.
395 If you don't want to use @file{.muse}, you can customize the extension
396 by setting the value of @code{muse-file-extension}.
398 If you don't want to use any extension at all, and want Muse to
399 autodetect project files based on their location, then add the following
400 to your Muse settings file.
402 @lisp
403 (setq muse-file-extension nil
404       muse-mode-auto-p t)
405 @end lisp
407 If you would like to include only some files from a directory in a Muse
408 project, you may use a regexp in place of @file{~/Pages} in the example.
410 @c PRE3_03: Give more examples
411 @c PRE3_03: Describe :set and other options fully
413 @node Keystroke Summary, Markup Rules, Projects, Top
414 @comment  node-name,  next,  previous,  up
415 @chapter Keys Used in Muse Mode
416 @cindex keystrokes
418 This is a summary of keystrokes available in every Muse buffer.
420 @table @kbd
422 @item C-c C-a (`muse-index')
423 Display an index of all known Muse pages.
425 @item C-c C-b (`muse-find-backlinks')
426 Find all pages that link to this page.
428 @item C-c C-e (`muse-edit-link-at-point')
429 Edit link at point.
431 @item C-c C-f (`muse-project-find-file')
432 Open another Muse page.  Prompt for the name.
434 @item C-c C-i (`muse-insert-tag')
435 Insert a tag interactively.
437 @item C-c C-l (`font-lock-mode')
438 Toggle font lock / highlighting for the current buffer.
440 @item C-c C-p (`muse-project-publish')
441 Publish any Muse pages that have changed.
443 @item C-c C-s (`muse-search')
444 Find text in all files of the current project.
446 @item C-c C-t (`muse-project-publish-this-file')
447 Publish the currently-visited file.  Prompt for the style if the current
448 file can be published using more than one style.
450 @item C-c C-T (`muse-publish-this-file')
451 Publish the currently-visited file.  Prompt for both the style and
452 output directory.
454 @item C-c C-v (`muse-browse-result')
455 Show the published result of this page.
457 @item C-c = (`muse-what-changed')
458 Diff this page against the last backup version.
460 @item C-c TAB l (`muse-insert-relative-link-to-file')
461 Insert a link to a file interactively.
463 @item C-c TAB t (`muse-insert-tag')
464 Insert a tag interactively.
466 @item C-c TAB u (`muse-insert-url')
467 Insert a URL interactively.
469 @item TAB
470 Move to the next Wiki reference.
472 @item S-TAB
473 Move to the previous Wiki reference.
475 @item M-TAB
476 Complete the name of a page from the current project at point.
478 @item M-RET
479 Insert a new list item at point, indenting properly.
481 @item C-<
482 Decrease the indentation of the list item at point.
484 @item C->
485 Increase the indentation of the list item at point.
487 @end table
490 @node Markup Rules, Publishing Styles, Keystroke Summary, Top
491 @comment  node-name,  next,  previous,  up
492 @chapter Rules for Using Markup
493 @cindex markup
495 A Muse document uses special, contextual markup rules to determine how
496 to format the output result.  For example, if a paragraph is indented,
497 Muse assumes it should be quoted.
499 There are not too many markup rules, and all of them strive to be as
500 simple as possible so that you can focus on document creation, rather
501 than formatting.
503 @menu
504 * Paragraphs::                  Paragraphs: centering and quoting.
505 * Headings::                    Levels of headings.
506 * Directives::                  Directives at the beginning of a
507                                   document.
508 * Emphasizing Text::            Bold, italicized, and underlined text.
509 * Footnotes::                   Making notes to be shown at the end.
510 * Verse::                       Indicating poetic stanzas.
511 * Lists::                       Lists of items.
512 * Tables::                      Generation of data tables.
513 * Explicit Links::              Hyperlinks and email addresses with
514                                   descriptions.
515 * Implicit Links::              Bare URLs, WikiNames, and InterWiki
516                                   links.
517 * Images::                      Publishing and displaying images.
518 * Horizontal Rules and Anchors::  Inserting a horizontal line or anchor.
519 * Embedded Lisp::               Evaluating Emacs Lisp code in documents
520                                   for extensibility.
521 * Comments::                    Lines to omit from published output.
522 * Tag Summary::                 Tags that Muse recognizes.
523 @end menu
525 @node Paragraphs, Headings, Markup Rules, Markup Rules
526 @comment  node-name,  next,  previous,  up
527 @section Paragraphs: centering and quoting
528 @cindex paragraphs
530 Paragraphs in Muse must be separated by a blank line.
532 @cindex paragraphs, centered
533 @subheading Centered paragraphs and quotations
535 A line that begins with six or more columns of whitespace (either tabs
536 or spaces) indicates a centered paragraph.  Alternatively, you can use
537 the @verb{|<center>|} tag to surround regions that are to be published as
538 centered paragraphs.
540 @cindex paragraphs, quoted
541 @cindex quotations
542 But if a line begins with whitespace, though less than six columns, it
543 indicates a quoted paragraph.  Alternatively, you can use the
544 @verb{|<quote>|} tag to surround regions that are to be published as
545 quoted paragraphs.
547 @cindex examples
548 @cindex monospace, rendering blocks
549 @cindex HTML, rendering blocks in monospace
550 @subheading Literal paragraphs
552 The @verb{|<example>|} tag is used for examples, where whitespace should
553 be preserved, the text rendered in monospace, and any characters special
554 to the output style escaped.
556 @cindex literal text
557 @cindex HTML, inserting a raw block
558 There is also the @verb{|<literal>|} tag, which causes a marked block to
559 be entirely left alone.  This can be used for inserting a hand-coded
560 HTML blocks into HTML output, for example.
562 @node Headings, Directives, Paragraphs, Markup Rules
563 @comment  node-name,  next,  previous,  up
564 @section Levels of headings
565 @cindex headings
567 A heading becomes a chapter or section in printed output -- depending on
568 the style.  To indicate a heading, start a new paragraph with one or
569 more asterices, followed by a space and the heading title.  Then begin
570 another paragraph to enter the text for that section.
572 All levels of headings will be published.  Most publishing styles only
573 distinguish the between the first 4 levels, however.
575 @example
576 * First level
578 ** Second level
580 *** Third level
582 **** Fourth level
583 @end example
585 @node Directives, Emphasizing Text, Headings, Markup Rules
586 @comment  node-name,  next,  previous,  up
587 @section Directives at the beginning of a document
588 @cindex directives
590 Directives are lines beginning with the @samp{#} character that come
591 before any paragraphs or sections in the document.  Directives are of
592 the form ``#directive content of directive''.  You can use any
593 combination of uppercase and lowercase letters for directives, even if
594 the directive is not in the list below.
596 The @code{muse-publishing-directive} function may be used in header and
597 footer text to access directives.  For example, to access the
598 @samp{#title} directive, use @code{(muse-publishing-directive "title")}.
600 The following is a list of directives that Muse uses.
602 @table @code
603 @cindex #author
604 @item #author
605 The author of this document.
607 If this is not specified, Muse will attempt to figure it out from the
608 @code{user-full-name} variable.
610 @cindex #date
611 @item #date
612 The date that the document was last modified.
614 This is used by publishing styles that are able to embed the date
615 information.
617 @cindex #desc
618 @item #desc
619 A short description of this document.
621 This is used by the @code{journal} publishing style to embed information
622 inside of an RSS/RDF feed.
624 @cindex #title
625 @item #title
626 The title of this document.
628 If this is not specified, the name of the file is used.
630 @end table
632 @node Emphasizing Text, Footnotes, Directives, Markup Rules
633 @comment  node-name,  next,  previous,  up
634 @section Bold, italicized, and underlined text
635 @cindex emphasizing text
636 @cindex underlining text
637 @cindex italicizing text
638 @cindex verbatim text
639 @cindex monospace, rendering words
641 To emphasize text, surround it with certain specially recognized
642 characters.
644 @example
645 *emphasis*
646 **strong emphasis**
647 ***very strong emphasis***
648 _underlined_
649 =verbatim and monospace=
650 @end example
652 @cindex WYSIWYG
653 While editing a Muse document in Muse mode, these forms of emphasis will
654 be highlighted in a WYSIWYG manner.  Each of these forms may span
655 multiple lines.
657 Verbatim text will be colored as gray by default.  To change this,
658 customize @code{muse-verbatim-face}.
660 You can also use the @verb{|<code>|} tag to indicate verbatim and
661 monospace text.  This is handy for regions that have an ``='' in them.
663 @node Footnotes, Verse, Emphasizing Text, Markup Rules
664 @comment  node-name,  next,  previous,  up
665 @section Making notes to be shown at the end
666 @cindex footnotes
668 A footnote reference is simply a number in square brackets.  To define
669 the footnote, place this definition at the bottom of your file.
670 @samp{footnote-mode} can be used to greatly facilitate the creation of
671 these kinds of footnotes.
673 Footnotes are defined by the same number in brackets occurring at the
674 beginning of a line.  Use footnote-mode's @kbd{C-c ! a} command, to very
675 easily insert footnotes while typing.  Use @kbd{C-x C-x} to return to
676 the point of insertion.
678 @node Verse, Lists, Footnotes, Markup Rules
679 @comment  node-name,  next,  previous,  up
680 @section Indicating poetic stanzas
681 @cindex verses
682 @cindex poetry
684 Poetry requires that whitespace be preserved, but without resorting to
685 monospace.  To indicate this, use the following markup, reminiscent of
686 email quotations.
688 @example
689 > A line of Emacs verse;
690 >   forgive its being so terse.
691 @end example
693 You can also use the @verb{|<verse>|} tag, if you prefer.
695 @example
696 <verse>
697 A line of Emacs verse;
698   forgive its being so terse.
699 </verse>
700 @end example
702 @cindex verses, multiple stanzas
703 Multiple stanzas may be included in one set of @verb{|<verse>|} tags, as
704 follows.
706 @example
707 <verse>
708 A line of Emacs verse;
709   forgive its being so terse.
711 In terms of terse verse,
712   you could do worse.
713 </verse>
714 @end example
716 @node Lists, Tables, Verse, Markup Rules
717 @comment  node-name,  next,  previous,  up
718 @section Lists of items
719 @cindex lists
721 Lists are given using special characters at the beginning of a line.
722 Whitespace must occur before bullets or numbered items, to distinguish
723 from the possibility of those characters occurring in a real sentence.
725 @cindex lists, bullets
726 These are rendered as a bullet list.
728 @example
729 - bullet item one
730 - bullet item two
731 @end example
733 @cindex lists, enumerated
734 An enumerated list follows.
736 @example
737 1. Enum item one
738 2. Enum item two
739 @end example
741 @cindex lists, definitions
742 Here is a definition list.
744 @example
745 Term1 ::
746   This is a first definition
747   And it has two lines;
748   no, make that three.
750 Term2 ::
751   This is a second definition
752 @end example
754 @node Tables, Explicit Links, Lists, Markup Rules
755 @comment  node-name,  next,  previous,  up
756 @section Generation of data tables
757 @cindex tables
759 @cindex tables, simple
760 Only very simple tables are supported.  The syntax is as follows.
762 @example
763 Double bars  || Separate header fields
765 Single bars   | Separate body fields
766 Here are more | body fields
768 Triple bars ||| Separate footer fields
769 @end example
771 Some publishing styles require header fields to come first, then footer
772 fields, and then the body fields.  You can use any order for these
773 sections that you like, and Muse will re-order them for you at
774 publish-time.
776 If you wish to disable table generation for one Muse file, add the
777 directive @samp{#disable-tables t} to the top of the file.
779 @node Explicit Links, Implicit Links, Tables, Markup Rules
780 @comment  node-name,  next,  previous,  up
781 @section Hyperlinks and email addresses with descriptions
782 @cindex links, explicit
784 A hyperlink can reference a URL, or another page within a Muse
785 project.  In addition, descriptive text can be specified, which should
786 be displayed rather than the link text in output styles that supports
787 link descriptions.  The syntax is as follows.
789 @example
790 [[link target][link description]]
791 [[link target without description]]
792 @end example
794 Thus, the current maintainer's homepage for Muse can be found
795 @samp{[[http://www.mwolson.org/projects/EmacsMuse.html][here]]},
796 or at @samp{[[http://www.mwolson.org/projects/EmacsMuse.html]]}.
798 @node Implicit Links, Images, Explicit Links, Markup Rules
799 @comment  node-name,  next,  previous,  up
800 @section Bare URLs, WikiNames, and InterWiki links
801 @cindex links, implicit
802 @cindex links, raw
804 @cindex URLs
805 @cindex Email addresses
807 A URL or email address encountered in the input text is published as a
808 hyperlink.  These kind of links are called @dfn{implicit links} because
809 they are not separated from the rest of the Muse document in any way.
811 Some characters in URLs will prevent Muse from recognizing them as
812 implicit links. If you want to link to a URL containing spaces or any of
813 the characters ``][,"'`()<>^'', you will have to make the link
814 explicit. The punctuation characters ``.,;:'' are also not recognized as
815 part of a URL when they appear at its end. For information on how to
816 make an explicit link, see @ref{Explicit Links,,Hyperlinks and email
817 addresses with descriptions}.
819 @cindex WikiNames
820 If the @command{muse-wiki} module is loaded, another form of implicit
821 link will be made available.  WikiNames, which are typed in CamelCase,
822 are highlighted and published as links, provided that the file they
823 refer to exists.
825 Customization of WikiName recognition may be accomplished by editing the
826 @code{muse-wiki-wikiword-regexp} option and subsequently running
827 @code{(muse-configure-highlighting 'muse-colors-markupmuse-colors-markup)}.
828 If you use the Customize interface, the latter will be done
829 automatically.
831 @cindex InterWiki links
832 @cindex inter-project links
833 The @command{muse-wiki} module also allows for InterWiki links.  These
834 are similar to WikiWords, but they specify both the project and page of
835 a file.  The names of your project entries in @code{muse-project-alist}
836 will be used as InterWiki names by default.  Several examples follow.
838 @example
839 Blog::DocumentingMuse
840 Projects#EmacsMuse
841 Website
842 @end example
844 In the first case, the interwiki delimiter is @samp{::}, @samp{Blog} is
845 the project name, and @samp{DocumentingMuse} is the page name.  In the
846 second example, @samp{#} is the interwiki delimiter.  If the name of a
847 project occurs by itself in text, like the third case, it will be
848 colorized and published as a link to the default page of the given
849 project.
851 Customization of interwiki links may be accomplished by editing the
852 @code{muse-wiki-interwiki-alist} option.
854 @node Images, Horizontal Rules and Anchors, Implicit Links, Markup Rules
855 @comment  node-name,  next,  previous,  up
856 @section Publishing and displaying images
857 @cindex images
858 @cindex links, with images
859 @subheading Image links
861 Links to images may be used in either the target or the description, or
862 both.  Thus, the following code will publish as a clickable image that
863 points to @url{http://www.mwolson.org/}.
865 @example
866 [[http://www.mwolson.org/][/static/logos/site-logo.png]]
867 @end example
869 @cindex images, displaying
870 @cindex images, local
871 @subheading Displaying images in Muse mode
872 If a link to a locally-available image is encountered in the link
873 description, Muse mode will attempt to display it if your version of
874 Emacs permits this.
876 This behavior may be toggled with @kbd{C-c C-i}, or disabled permanently
877 by setting the @code{muse-colors-inline-images} option to @code{nil}.
879 The method for finding images may be altered by customizing the
880 @code{muse-colors-inline-image-method} option.  One useful value for
881 this option is @code{muse-colors-use-publishing-directory}, which tells
882 Muse mode to look in the directory where the current file will be
883 published.  The default is to look in the current directory.  Relative
884 paths like @samp{../pics/} should work for either setting.
886 Eventually, it is hoped that Muse will be able to copy images from the a
887 ``source'' directory to a publishing directory by customizing
888 @code{muse-project-alist}, but this has not been implemented yet.
890 @cindex images, without descriptions
891 @cindex images, inlined
892 @subheading Publishing simple images
893 The following example will display correctly and publish correctly if a
894 @acronym{PNG} file called @file{TestLogo.png} exists in the
895 @file{../pics/} directory.  If text is on the same line as the picture,
896 it will remain so in the output.
898 @example
899 [[../myimage.png]]
900 @end example
902 @cindex images, captions
903 @subheading Publishing images with captions
904 If you want to add a caption to an image, use the following syntax.
905 This will center the image (if the output format supports it) and add a
906 centered caption below the picture.  Formats that do not support
907 centering the image will instead leave it against the left margin.
909 @example
910 [[../pics/mycat.png][My cat Dexter]]
911 @end example
913 Images with captions may only occur in their own paragraphs, with no
914 text on the same line.  Otherwise, the published output will not be
915 syntactically correct.
917 @node Horizontal Rules and Anchors, Embedded Lisp, Images, Markup Rules
918 @comment  node-name,  next,  previous,  up
919 @section Inserting a horizontal line or anchor
921 @cindex horizontal rules
922 @cindex dashes
923 @subheading Horizontal Rules
925 Four or more dashes indicate a horizontal rule.  Be sure to put blank
926 lines around it, or it will be considered part of the proceeding or
927 following paragraph!
929 @cindex anchors
930 @cindex links, with target on same page
931 @subheading Anchors
933 If you begin a line with "#anchor" -- where "anchor" can be any word
934 that doesn't contain whitespace -- it defines an anchor at that point
935 into the document.  This point can be referenced using "page#anchor" as
936 the target in a Muse link.
938 @node Embedded Lisp, Comments, Horizontal Rules and Anchors, Markup Rules
939 @comment  node-name,  next,  previous,  up
940 @section Evaluating Emacs Lisp code in documents for extensibility
941 @cindex lisp, embedded
943 Arbitrary kinds of markup can be achieved using the @verb{|<lisp>|} tag,
944 which is the only Muse tag supported in a style's header and footer
945 text.  With the @verb{|<lisp>|} tag, you may generated whatever output
946 text you wish.  The inserted output will get marked up, if the
947 @verb{|<lisp>|} tag appears within the main text of the document.
949 @example
950 <lisp>(concat "This form gets " "inserted")</lisp>
951 @end example
953 @cindex lisp, and insert command
954 Note that you should not use the @code{insert} command within a set of
955 @verb{|<lisp>|} tags, since the return value from the @verb{|<lisp>|}
956 tags will be automatically inserted into the document.
958 @node Comments, Tag Summary, Embedded Lisp, Markup Rules
959 @comment  node-name,  next,  previous,  up
960 @section Lines to omit from published output
961 @cindex comments
962 @cindex publishing, omitting lines
964 Use the following syntax to indicate a comment.  Comments will not be
965 published.
967 @example
968 ; Comment text goes here.
969 @end example
971 That is, only a semi-colon at the beginning of a line, followed by a
972 literal space, will cause that line to be treated as a comment.
974 @node Tag Summary, , Comments, Markup Rules
975 @comment  node-name,  next,  previous,  up
976 @section Tags that Muse recognizes
977 @cindex tags
978 @cindex inserting files at publish time
979 @cindex publishing, including markup in headers and footers
980 @cindex publishing, inserting files
982 Muse has several built-in tags that may prove useful during publishing.
983 @xref{muse-publish-markup-tags}, to see how to customize the tags that
984 Muse uses, as well as make your own tags.
986 @subheading Syntax
988 If a tag takes arguments, it will look like this, where ``tagname'' is
989 the name of the tag.
991 @example
992 <tagname arg1="string1" arg2="string2">
993 @end example
995 If you want the tag to look like it came straight from an XHTML
996 document, you can alternatively do the following.
998 @example
999 <tagname arg1="string1" arg2="string2" />
1000 @end example
1002 If a tag surrounds some text, it will look like this.
1004 @example
1005 <tagname>Some text</tagname>
1006 @end example
1008 If a tag surrounds a large region, it will look like this.
1010 @example
1011 <tagname>
1012 Some text.
1013 Some more text.
1014 </tagname>
1015 @end example
1017 @subheading Tag listing
1019 This is the complete list of tags that Muse accepts, including those
1020 that were mentioned in previous sections.
1022 @table @samp
1024 @item <class>
1025 If publishing to HTML, surround the given text with a @verb{|<span>|}
1026 tag.  It takes one argument called ``name'' that specifies the class
1027 attribute of the @verb{|<span>|} tag.
1029 If publishing to a different format, do nothing extra to the text.
1031 @item <code>
1032 Treat the text surrounded by the tag as if they were enclosed in equal
1033 signs, that is, make it monospace.
1035 @item <command>
1036 Run a command on the region, replacing the region with the result of the
1037 command.  The command is specified with the ``interp'' argument.  If no
1038 value for ``interp'' is given, pass the entire region to the shell.
1040 The ``markup'' argument controls how this section is marked up.
1042 If it is omitted, publish the region with the normal Muse rules.
1044 If "nil", do not mark up the region at all, but prevent Muse from
1045 further interpreting it.
1047 If "example", treat the region as if it was surrounded by the
1048 @verb{|<example>|} tag.
1050 If "verse", treat the region as if it was surrounded by the
1051 @verb{|<verse>|} tag, to preserve newlines.
1053 Otherwise, it should be the name of a function to call, with the buffer
1054 narrowed to the region.
1056 @item <comment>
1057 Treat the entire region as a comment.  If the option
1058 @var{muse-publish-comments-p} is nil, delete the region, otherwise
1059 publish it using the comment syntax of the current publishing style.
1061 @item <contents>
1062 Publish a Table of Contents.  This will either be inserted in-place or
1063 at the beginning of the document, depending on your publishing style.
1064 It does not have a delimiting tag.
1066 By default, only 2 levels of headings will be included in the generated
1067 Table of Contents.  To change this globally, customize the
1068 @var{muse-publish-contents-depth} option.  To change this only for the
1069 current tag, use the ``depth'' argument.
1071 @item <example>
1072 Publish the region in monospace, preserving the newlines in the region.
1073 This is useful for snippets of code.
1075 @item <include>
1076 Insert the given file at the current location during publishing.  The
1077 basic use of this tag is as follows, replacing ``included_file'' with
1078 the name of the file that you want to include.
1080 @example
1081 <include file="included_file">
1082 @end example
1084 The ``markup'' argument controls how this section is marked up.
1086 If it is omitted, publish the included text with the normal Muse
1087 rules.
1089 If "nil", do not mark up the included text at all.
1091 If "example", treat the included text as if it was surrounded by the
1092 @verb{|<example>|} tag.
1094 If "verse", treat the included text as if it was surrounded by the
1095 @verb{|<verse>|} tag, to preserve newlines.
1097 Otherwise, it should be the name of a function to call after inserting
1098 the file with the buffer narrowed to the section inserted.
1100 @item <lisp>
1101 Evaluate the Emacs Lisp expressions between the initial and ending tags.
1102 The result is then inserted into the document, so you do not need to
1103 explicitly call @code{insert}.  All text properties are removed from the
1104 resulting text.
1106 This tag takes the ``markup'' argument.  See the description of
1107 @verb{|<command>|} for details.
1109 @item <literal>
1110 Make sure that the text enclosed by this tag is published without
1111 escaping it in any way.  This is useful for inserting markup directly
1112 into the published document, when Muse does not provide the desired
1113 functionality.
1115 @item <markup>
1116 Mark up the text between the initial and ending tags.  The markup
1117 command to use may be specified by the ``function'' argument.  The
1118 standard Muse markup routines are used by default if no ``function''
1119 argument is provided.
1121 This is useful for marking up regions in headers and footers.  One
1122 example that comes to mind is generating a published index of all of the
1123 files in the current project by doing the following.
1125 @example
1126 <markup><lisp>(muse-index-as-string t t)</lisp></markup>
1127 @end example
1129 @item <perl>
1130 Run the @command{perl} language interpreter on the region, replacing the
1131 region with the result of the command.
1133 This tag takes the ``markup'' argument.  See the description of
1134 @verb{|<command>|} for details.
1136 @item <python>
1137 Run the @command{python} language interpreter on the region, replacing
1138 the region with the result of the command.
1140 This tag takes the ``markup'' argument.  See the description of
1141 @verb{|<command>|} for details.
1143 @item <quote>
1144 Publish the region as a blockquote.  This will either be inserted
1145 in-place or at the beginning of the document, depending on your
1146 publishing style.  It does not have a delimiting tag.
1148 @item <ruby>
1149 Run the @command{ruby} language interpreter on the region, replacing the
1150 region with the result of the command.
1152 This tag takes the ``markup'' argument.  See the description of
1153 @verb{|<command>|} for details.
1155 @item <verbatim>
1156 This is used when you want to prevent Muse from trying to interpret some
1157 markup.  Surround the markup in @verb{|<verbatim>|} and
1158 @verb{|</verbatim>|}, and it will not be interpreted.
1160 This tag was used often in previous versions of Muse because they did
1161 not support whole-document escaping of specials.  Now, it will only be
1162 needed for other tags, and perhaps footnotes as well.
1164 @item <verse>
1165 Preserve the newlines in the region.  In formats like HTML, newlines are
1166 removed by default, hence the need for this tag.  In other publishing
1167 styles, this tag may cause the text to be indented slightly in a way
1168 that looks nice for poetry and prose.
1170 @end table
1172 @node Publishing Styles, Extending Muse, Markup Rules, Top
1173 @comment  node-name,  next,  previous,  up
1174 @chapter Publishing Various Types of Documents
1175 @cindex publishing styles
1177 One of the principle features of Muse is the ability to publish a simple
1178 input text to a variety of different output styles.  Muse also makes it
1179 easy to create new styles, or derive from an existing style.
1181 @menu
1182 * Blosxom::                     Integrating Muse and pyblosxom.cgi.
1183 * Book::                        Publishing entries into a compilation.
1184 * DocBook::                     Publishing in DocBook XML form.
1185 * HTML::                        Publishing in HTML or XHTML form.
1186 * Journal::                     Keeping a journal or blog.
1187 * LaTeX::                       Publishing LaTeX documents.
1188 * Poem::                        Publish a poem to LaTex or PDF.
1189 * Texinfo::                     Publish entries to Texinfo format or PDF.
1190 @end menu
1192 @node Blosxom, Book, Publishing Styles, Publishing Styles
1193 @comment  node-name,  next,  previous,  up
1194 @section Integrating Muse and pyblosxom.cgi
1195 @cindex blog, one-file-per-entry style
1197 The Blosxom publishing style publishes a tree of categorised files to a
1198 mirrored tree of stories to be served by blosxom.cgi or pyblosxom.cgi.
1199 In other words, each blog entry corresponds with one file.
1201 @menu
1202 * Blosxom Requirements::        Other tools needed for the Blosxom style.
1203 * Blosxom Entries::             Format of a Blosxom entry and automation.
1204 * Blosxom Options::             Blosxom styles and options provided.
1205 @end menu
1207 @node Blosxom Requirements, Blosxom Entries, Blosxom, Blosxom
1208 @comment  node-name,  next,  previous,  up
1209 @subsection Other tools needed for the Blosxom style
1211 You will need to have @command{pyblosxom.cgi} or @command{blosxom.cgi}
1212 installed on a machine that you have upload access to.
1214 The following additional components are required in order to make the
1215 date of blog entries display as something sensible.
1217 @enumerate
1218 @item
1219 A script to gather date directives from the entire blog tree into a
1220 single file.  The file must associate a blog entry with a date.
1222 @item
1223 A plugin for (py)blosxom that reads this file.
1224 @end enumerate
1226 These 2 things are provided for @command{pyblosxom.cgi} in the
1227 @file{contrib/pyblosxom} subdirectory.  @file{getstamps.py} provides the
1228 former service, while @file{hardcodedates.py} provides the latter
1229 service.  Eventually it is hoped that a @command{blosxom.cgi} plugin and
1230 script will be found/written.
1232 Here is a sample listing from my @file{timestamps} file, which maps
1233 each file to a date.  This can really be in any format, as long as your
1234 date-gathering script and your plugin can both understand it.
1236 @example
1237 2005-04-01-14-16 personal/paper_cranes
1238 2005-03-21 personal/spring_break_over
1239 2004-10-24 personal/finished_free_culture
1240 @end example
1242 The script @file{contrib/pyblosxom/make-blog} demonstrates how to call
1243 @file{getstamps.py}.  Note that you will need to set the current
1244 directory to where your Muse files are, execute @file{getstamps.py}, and
1245 then move the generated timestamps file to your publishing directory.
1247 @node Blosxom Entries, Blosxom Options, Blosxom Requirements, Blosxom
1248 @comment  node-name,  next,  previous,  up
1249 @subsection Format of a Blosxom entry and automation
1251 Each Blosxom file must include `#date yyyy-mm-dd', or optionally the
1252 longer `#date yyyy-mm-dd-hh-mm', a title (using the #title directive),
1253 plus whatever normal content is desired.
1255 The date directive is not used directly by @command{pyblosxom.cgi} or
1256 this program.  You need to have the two additional items from the former
1257 section to make use of this feature.
1259 There is a function called @code{muse-blosxom-new-entry} that will
1260 automate the process of making a new blog entry.  To make use of it, do
1261 the following.
1263 @itemize @bullet
1264 @item
1265 Customize @code{muse-blosxom-base-directory} to the location that your
1266 blog entries are stored.
1268 @item
1269 Assign the @code{muse-blosxom-new-entry} function to a key sequence.  I
1270 use the following code to assign this function to @kbd{C-c p l'}.
1272 @example
1273 (global-set-key "\C-cpl" 'muse-blosxom-new-entry)
1274 @end example
1276 @item
1277 You should create your directory structure ahead of time under your base
1278 directory.  These directories, which correspond with category names, may
1279 be nested.
1281 @item
1282 When you enter this key sequence, you will be prompted for the category
1283 of your entry and its title.  Upon entering this information, a new file
1284 will be created that corresponds with the title, but in lowercase
1285 letters and having special characters converted to underscores.  The
1286 title and date directives will be inserted automatically.
1287 @end itemize
1289 @node Blosxom Options, , Blosxom Entries, Blosxom
1290 @comment  node-name,  next,  previous,  up
1291 @subsection Blosxom styles and options provided
1293 The following styles and options are available in the Blosxom publishing
1294 style.
1296 @subheading Styles provided
1298 @table @code
1300 @cindex publishing styles, blosxom-html
1301 @item blosxom-html
1302 Publish Blosxom entries in HTML form.
1304 @cindex publishing styles, blosxom-xhtml
1305 @item blosxom-xhtml
1306 Publish Blosxom entries in XHTML form.
1308 @end table
1310 @subheading Options provided
1312 @table @code
1314 @item muse-blosxom-extension
1315 Default file extension for publishing Blosxom files.
1317 @item muse-blosxom-header
1318 Header used for publishing Blosxom files.
1320 This may be text or a filename.
1322 @item muse-blosxom-footer
1323 Footer used for publishing Blosxom files.
1325 This may be text or a filename.
1327 @item muse-blosxom-base-directory
1328 Base directory of blog entries, used by @code{muse-blosxom-new-entry}.
1330 This is the top-level directory where your blog entries may be found
1331 locally.
1333 @end table
1335 @node Book, DocBook, Blosxom, Publishing Styles
1336 @comment  node-name,  next,  previous,  up
1337 @section Publishing entries into a compilation
1339 This publishing style is used to output ``books'' in LaTeX or PDF
1340 format.
1342 Each page will become a separate chapter in the book, unless the style
1343 keyword @option{:nochapters} is used, in which case they are all run
1344 together as if one giant chapter.
1346 You will need to call the @code{muse-book-publish-project} function in
1347 order to publish this style.  An example of this may be found in John
1348 Wiegley's configuration file at @file{examples/johnw/muse-johnw.el}.
1350 @subheading Styles provided
1352 @table @code
1354 @cindex publishing styles, book-latex
1355 @item book-latex
1356 Publish a book in LaTeX form.  The header and footer are different than
1357 the normal LaTeX publishing mode.
1359 @cindex publishing styles, book-pdf
1360 @item book-pdf
1361 Publish a book in PDF form.  The header and footer are different than
1362 the normal PDF publishing mode.
1364 @end table
1366 @subheading Options provided
1368 @table @code
1370 @item muse-book-before-publish-hook
1371 A hook run in the book buffer before it is marked up.
1373 @item muse-book-after-publish-hook
1374 A hook run in the book buffer after it is marked up.
1376 @item muse-book-latex-header
1377 Header used for publishing books to LaTeX.
1379 This may be text or a filename.
1381 @item muse-book-latex-footer
1382 Footer used for publishing books to LaTeX.
1384 This may be text or a filename.
1386 @end table
1388 @node DocBook, HTML, Book, Publishing Styles
1389 @comment  node-name,  next,  previous,  up
1390 @section Publishing in DocBook XML form
1392 This publishing style is used to generate DocBook XML files.
1394 @subheading Styles provided
1396 @table @code
1398 @cindex publishing styles, docbook
1399 @item docbook
1401 @end table
1403 @subheading Options provided
1405 @table @code
1407 @item muse-docbook-extension
1408 Default file extension for publishing DocBook XML files.
1410 @item muse-docbook-header
1411 Header used for publishing DocBook XML files.
1413 This may be text or a filename.
1415 @item muse-docbook-footer
1416 Footer used for publishing DocBook XML files.
1418 This may be text or a filename.
1420 @item muse-docbook-markup-regexps
1421 List of markup rules for publishing a Muse page to DocBook XML.
1423 @item muse-docbook-markup-functions
1424 An alist of style types to custom functions for that kind of text.
1426 @item muse-docbook-markup-strings
1427 Strings used for marking up text.
1429 These cover the most basic kinds of markup, the handling of which
1430 differs little between the various styles.
1432 @item muse-docbook-markup-specials
1433 A table of characters which must be represented specially.
1435 @item muse-docbook-encoding-default
1436 The default Emacs buffer encoding to use in published files.
1437 This will be used if no special characters are found.
1439 @item muse-docbook-charset-default
1440 The default DocBook XML charset to use if no translation is
1441 found in @code{muse-docbook-encoding-map}.
1443 @item muse-docbook-encoding-map
1444 An alist mapping emacs coding systems to appropriate DocBook charsets.
1445 Use the base name of the coding system (i.e. without the -unix).
1447 @end table
1449 @node HTML, Journal, DocBook, Publishing Styles
1450 @comment  node-name,  next,  previous,  up
1451 @section Publishing in HTML or XHTML form
1453 This publishing style is capable of producing HTML or XHTML documents.
1455 @subheading Styles provided
1457 @table @code
1459 @cindex publishing styles, html
1460 @item html
1461 Supports publishing to HTML 4.0 and HTML 4.01, Strict or Transitional.
1463 @item xhtml
1464 Supports publishing to XHTML 1.0 and XHTML 1.1, Strict or Transitional.
1466 @end table
1468 @subheading Options provided
1470 If an HTML option does not have a corresponding XHTML option, it will
1471 be used for both of these publishing styles.
1473 @table @code
1475 @item muse-html-extension
1476 Default file extension for publishing HTML files.
1478 @item muse-xhtml-extension
1479 Default file extension for publishing XHTML files.
1481 @item muse-html-style-sheet
1482 Store your stylesheet definitions here.
1484 This is used in @code{muse-html-header}.  You can put raw CSS in here or
1485 a @verb{|<link>|} tag to an external stylesheet.  This text may contain
1486 @verb{|<lisp>|} markup tags.
1488 If you are using XHTML, make sure to close the @verb{|<link>|} tag
1489 properly.
1491 @item muse-html-header
1492 Header used for publishing HTML files.
1494 This may be text or a filename.
1496 @item muse-html-footer
1497 Footer used for publishing HTML files.
1499 This may be text or a filename.
1501 @item muse-xhtml-header
1502 Header used for publishing XHTML files.
1504 This may be text or a filename.
1506 @item muse-xhtml-footer
1507 Footer used for publishing XHTML files.
1509 This may be text or a filename.
1511 @item muse-html-anchor-on-word
1512 When true, anchors surround the closest word.
1514 This allows you to select them in a browser (i.e. for pasting), but has
1515 the side-effect of marking up headers in multiple colors if your header
1516 style is different from your link style.
1518 @item muse-html-table-attributes
1519 The attribute to be used with HTML @verb{|<table>|} tags.
1521 If you want to make more-complicated tables in HTML, surround the HTML
1522 with the @verb{|literal|} tag, so that it does not get escaped.
1524 @item muse-html-markup-regexps
1525 List of markup rules for publishing a Muse page to HTML.
1527 @item muse-html-markup-functions
1528 An alist of style types to custom functions for that kind of text.
1530 @item muse-html-markup-strings
1531 Strings used for marking up text as HTML.
1533 These cover the most basic kinds of markup, the handling of which
1534 differs little between the various styles.
1536 @item muse-xhtml-markup-strings
1537 Strings used for marking up text as XHTML.
1539 These cover the most basic kinds of markup, the handling of which
1540 differs little between the various styles.
1542 @item muse-html-markup-tags
1543 A list of tag specifications, for specially marking up HTML.
1544 @xref{muse-publish-markup-tags}, for more information.
1546 @item muse-html-markup-specials
1547 A table of characters which must be represented specially.  By default,
1548 this includes @samp{"}, @samp{<}, @samp{>}, and @samp{&}.
1550 @item muse-html-meta-http-equiv
1551 The http-equiv attribute used for the HTML @verb{|<meta>|} tag.
1553 @item muse-html-meta-content-type
1554 The content type used for the HTML @verb{|<meta>|} tag.
1556 If you are striving for XHTML 1.1 compliance, you may want to change
1557 this to ``application/xhtml+xml''.
1559 @item muse-html-meta-content-encoding
1560 The charset to append to the HTML @verb{|<meta>|} tag.
1562 If set to the symbol 'detect, use @code{muse-html-encoding-map} to try
1563 and determine the HTML charset from emacs's coding.  If set to a string,
1564 this string will be used to force a particular charset.
1566 @item muse-html-charset-default
1567 The default HTML meta charset to use if no translation is found in
1568 @code{muse-html-encoding-map}.
1570 @item muse-html-encoding-default
1571 The default Emacs buffer encoding to use in published files.
1572 This will be used if no special characters are found.
1574 @item muse-html-encoding-map
1575 An alist mapping emacs coding systems to appropriate HTML charsets.
1576 Use the base name of the coding system (i.e. without the -unix).
1578 @end table
1580 @node Journal, LaTeX, HTML, Publishing Styles
1581 @comment  node-name,  next,  previous,  up
1582 @section Keeping a journal or blog
1583 @cindex journal
1584 @cindex blog, journal style
1586 The module facilitates the keeping and publication of a journal.  When
1587 publishing to HTML, it assumes the form of a web log, or blog.
1589 The input format for each entry is as follows.
1591 @example
1592 * 20040317: Title of entry
1594 text for the entry.
1596 <qotd>
1597 "You know who you are. It comes down to a simple gut check: You
1598 either love what you do or you don't. Period." -- P. Bronson
1599 </qotd>
1600 @end example
1602 The "qotd", or Quote of the Day, is entirely optional.  When generated
1603 to HTML, this entry is rendered as the following.
1605 @example
1606 <div class="entry">
1607   <div class="entry-qotd">
1608     <h3>Quote of the Day:</h3>
1609     <p>"You know who you are. It comes down to a simple gut
1610       check: You either love what you do or you don't. Period."
1611       -- P. Bronson</p>
1612   </div>
1613   <div class="entry-body">
1614     <div class="entry-head">
1615       <div class="entry-date">
1616         <span class="date">March 17, 2004</span>
1617       </div>
1618       <div class="entry-title">
1619         <h2>Title of entry</h2>
1620       </div>
1621     </div>
1622     <div class="entry-text">
1623       <p>Text for the entry.</p>
1624     </div>
1625   </div>
1626 </div>
1627 @end example
1629 The plurality of "div" tags makes it possible to display the entries in
1630 any form you wish, using a CSS style.
1632 Also, an .RDF file can be generated from your journal by publishing it
1633 with the "rdf" style.  It uses the first two sentences of the first
1634 paragraph of each entry as its "description", and auto-generates tags
1635 for linking to the various entries.
1637 @subheading Styles provided
1639 @table @code
1641 @cindex publishing styles, journal-html
1642 @item journal-html
1643 Publish journal entries as an HTML document.
1645 @cindex publishing styles, journal-xhtml
1646 @item journal-xhtml
1647 Publish journal entries as an XHTML document.
1649 @cindex publishing styles, journal-latex
1650 @item journal-latex
1651 Publish journal entries as a LaTeX document.
1653 @cindex publishing styles, journal-pdf
1654 @item journal-pdf
1655 Publish journal entries as a PDF document.
1657 @cindex publishing styles, journal-book-latex
1658 @item journal-book-latex
1659 Publish journal entries as a LaTeX book.
1661 @cindex publishing styles, journal-book-pdf
1662 @item journal-book-pdf
1663 Publish journal entries as a PDF book.
1665 @cindex publishing styles, journal-rdf
1666 @cindex publishing styles, RSS 1.0
1667 @item journal-rdf
1668 Publish journal entries as an RDF file (RSS 1.0).
1670 @cindex publishing styles, journal-rss
1671 @cindex publishing styles, RSS 2.0
1672 @item journal-rss
1673 Publish journal entries as an RSS file (RSS 2.0).
1675 @end table
1677 @subheading Options provided
1679 @table @code
1681 @item muse-journal-heading-regexp
1682 A regexp that matches a journal heading.
1684 Paren group 1 is the ISO date, group 2 is the optional category, and
1685 group 3 is the optional heading for the entry.
1687 @item muse-journal-date-format
1688 Date format to use for journal entries.
1690 @item muse-journal-html-heading-regexp
1691 A regexp that matches a journal heading from an HTML document.
1693 Paren group 1 is the ISO date, group 2 is the optional category, and
1694 group 3 is the optional heading for the entry.
1696 @item muse-journal-html-entry-template
1697 Template used to publish individual journal entries as HTML.
1699 @item muse-journal-latex-section
1700 Template used to publish a LaTeX section.
1702 @item muse-journal-latex-subsection
1703 Template used to publish a LaTeX subsection.
1705 @item muse-journal-latex-markup-tags
1706 A list of tag specifications, for specially marking up LaTeX.
1708 @xref{muse-publish-markup-tags}, for more information.
1710 @item muse-journal-rdf-extension
1711 Default file extension for publishing RDF (RSS 1.0) files.
1713 @item muse-journal-rdf-base-url
1714 The base URL of the website referenced by the RDF file.
1716 @item muse-journal-rdf-header
1717 Header used for publishing RDF (RSS 1.0) files.
1719 This may be text or a filename.
1721 @item muse-journal-rdf-footer
1722 Footer used for publishing RDF (RSS 1.0) files.
1724 This may be text or a filename.
1726 @item muse-journal-rdf-date-format
1727 Date format to use for RDF entries.
1729 @item muse-journal-rdf-entry-template
1730 Template used to publish individual journal entries as RDF.
1732 @item muse-journal-rdf-summarize-entries
1733 If non-nil, include only summaries in the RDF file, not the full data.
1735 @item muse-journal-rss-extension
1736 Default file extension for publishing RSS 2.0 files.
1738 @item muse-journal-rss-base-url
1739 The base URL of the website referenced by the RSS file.
1741 @item muse-journal-rss-header
1742 Header used for publishing RSS 2.0 files.
1744 This may be text or a filename.
1746 @item muse-journal-rss-footer
1747 Footer used for publishing RSS 2.0 files.
1749 This may be text or a filename.
1751 @item muse-journal-rss-date-format
1752 Date format to use for RSS 2.0 entries.
1754 @item muse-journal-rss-entry-template
1755 Template used to publish individual journal entries as RSS 2.0.
1757 @item muse-journal-rss-enclosure-types-alist
1758 File types that are accepted as RSS enclosures.
1760 This is an alist that maps file extension to content type.
1762 Useful for podcasting.
1764 @item muse-journal-rss-summarize-entries
1765 If non-nil, include only summaries in the RSS file, not the full data.
1767 Many RSS subscribers find this annoying.
1769 @item muse-journal-rss-markup-regexps
1770 List of markup rules for publishing a Muse journal page to RSS.
1772 For more information on the structure of this list,
1773 @xref{muse-publish-markup-regexps}.
1775 @item muse-journal-rss-markup-functions
1776 An alist of style types to custom functions for that kind of text.
1778 For more on the structure of this list,
1779 @xref{muse-publish-markup-functions}.
1781 @end table
1783 @node LaTeX, Poem, Journal, Publishing Styles
1784 @comment  node-name,  next,  previous,  up
1785 @section Publishing LaTeX documents
1787 This publishing style is capable of producing LaTeX or PDF documents.
1789 If you wish to publish PDF documents, you will need to have a good TeX
1790 installation.  For Debian and Ubuntu, this can be accomplished by
1791 installing the ``tetex-bin'' and ``tetex-extra'' packages.  TeX fonts
1792 are also a must.
1794 @subheading Styles provided
1796 @table @code
1798 @cindex publishing styles, latex
1799 @item latex
1800 Publish a LaTeX document.
1802 @cindex publishing styles, pdf
1803 @item pdf
1804 Publish a PDF document, using an external LaTeX document conversion
1805 tool.
1807 @cindex publishing styles, latexcjk
1808 @item latexcjk
1809 Publish a LaTeX document with CJK (Chinese) encodings.
1811 @cindex publishing styles, pdfcjk
1812 @item pdfcjk
1813 Publish a PDF document with CJK (Chinese) encodings, using an external
1814 LaTeX document conversion tool.
1816 @end table
1818 @subheading Options provided
1820 @table @code
1822 @item muse-latex-extension
1823 Default file extension for publishing LaTeX files.
1825 @item muse-latex-pdf-extension
1826 Default file extension for publishing LaTeX files to PDF.
1828 @item muse-latex-header
1829 Header used for publishing LaTeX files.
1831 This may be text or a filename.
1833 @item muse-latex-footer
1834 Footer used for publishing LaTeX files.
1836 This may be text or a filename.
1838 @item muse-latexcjk-header
1839 Header used for publishing LaTeX files (CJK).
1841 This may be text or a filename.
1843 @item muse-latexcjk-footer
1844 Footer used for publishing LaTeX files (CJK).
1846 This may be text or a filename.
1848 @item muse-latex-markup-regexps
1849 List of markup regexps for identifying regions in a Muse page.
1851 For more on the structure of this list,
1852 @xref{muse-publish-markup-regexps}.
1854 @item muse-latex-markup-functions
1855 An alist of style types to custom functions for that kind of text.
1857 For more on the structure of this list,
1858 @xref{muse-publish-markup-functions}.
1860 @item muse-latex-markup-strings
1861 Strings used for marking up text.
1863 These cover the most basic kinds of markup, the handling of which
1864 differs little between the various styles.
1866 @item muse-latexcjk-encoding-map
1867 An alist mapping emacs coding systems to appropriate CJK codings.
1868 Use the base name of the coding system (ie, without the -unix).
1870 @item muse-latexcjk-encoding-default
1871 The default Emacs buffer encoding to use in published files.
1873 This will be used if no special characters are found.
1875 @item muse-latex-markup-specials-example
1876 A table of characters which must be represented specially.
1877 These are applied to @verb{|example>|} regions.
1879 With the default interpretation of @verb{|<example>|} regions, no
1880 specials need to be escaped.
1882 @item muse-latex-markup-specials-document
1883 A table of characters which must be represented specially.
1884 These are applied to the entire document, sans already-escaped
1885 regions.
1887 @item muse-latex-markup-specials-literal
1888 A table of characters which must be represented specially.
1889 This applies to =monospaced text= and @verb{|<code>|} regions.
1891 @item muse-latex-markup-specials-url
1892 A table of characters which must be represented specially.
1893 These are applied to URLs.
1895 @item muse-latex-permit-contents-tag
1896 If nil, ignore @verb{|<contents>|} tags.  Otherwise, insert table of
1897 contents.
1899 Most of the time, it is best to have a table of contents on the
1900 first page, with a new page immediately following.  To make this
1901 work with documents published in both HTML and LaTeX, we need to
1902 ignore the @verb{|<contents>|} tag.
1904 If you don't agree with this, then set this option to non-nil,
1905 and it will do what you expect.
1907 @end table
1909 @node Poem, Texinfo, LaTeX, Publishing Styles
1910 @comment  node-name,  next,  previous,  up
1911 @section Publish a poem to LaTex or PDF
1913 The @code{muse-poem} module makes it easy to attractively publish and
1914 reference poems in the following format, using the "memoir" module for
1915 LaTeX publishing.  It will also markup poems for every other output
1916 style, though none are nearly as pretty.
1918 @example
1919 Title
1922 Body of poem
1925 Annotations, history, notes, etc.
1926 @end example
1928 Once a poem is written in this format, just publish it to PDF using the
1929 @code{poem-pdf} style.  To make an inlined reference to a poem that
1930 you've written -- for example, from a blog page -- there is a "poem" tag
1931 defined by this module.
1933 @example
1934 <poem title="name.of.poem.page">
1935 @end example
1937 Let's assume the template above was called @file{name.of.poem.page};
1938 then the above tag would result in this inclusion.
1940 @example
1941 ** Title
1943 > Body of poem
1944 @end example
1946 John Wiegley uses this module for publishing all of the poems on his
1947 website, which are at
1948 @uref{http://www.newartisans.com/johnw/poems.html}.
1950 @subheading Styles provided
1952 @table @code
1954 @cindex publishing styles, poem-latex
1955 @item poem-latex
1956 Publish a poem in LaTeX form.
1958 @cindex publishing styles, poem-pdf
1959 @item poem-pdf
1960 Publish a poem to a PDF document.
1962 @cindex publishing styles, chapbook-latex
1963 @item chapbook-latex
1964 Publish a book of poems in LaTeX form.
1966 @cindex publishing styles, chapbook-pdf
1967 @item chapbook-pdf
1968 Publish a book of poems to a PDF document.
1970 @end table
1972 @subheading Options provided
1974 @table @code
1976 @item muse-poem-latex-header
1977 Header used for publishing LaTeX poems.
1979 This may be text or a filename.
1981 @item muse-poem-latex-footer
1982 Footer used for publishing LaTeX files.
1984 This may be text or a filename.
1986 @item muse-poem-markup-strings
1987 Strings used for marking up poems.
1989 These cover the most basic kinds of markup, the handling of which
1990 differs little between the various styles.
1992 @item muse-chapbook-latex-header
1993 Header used for publishing a book of poems in LaTeX form.
1995 This may be text or a filename.
1997 @item muse-chapbook-latex-footer
1998 Footer used for publishing a book of poems in LaTeX form.
2000 This may be text or a filename.
2002 @item muse-poem-chapbook-strings
2003 Strings used for marking up books of poems.
2005 These cover the most basic kinds of markup, the handling of which
2006 differs little between the various styles.
2008 @end table
2010 @node Texinfo, , Poem, Publishing Styles
2011 @comment  node-name,  next,  previous,  up
2012 @section Publish entries to Texinfo format or PDF
2014 Rules for publishing a Muse file as a Texinfo article.
2016 @subheading Styles provided
2018 @table @code
2020 @cindex publishing styles, texi
2021 @item texi
2022 Publish a file in Texinfo form.
2024 @cindex publishing styles, texi
2025 @item info
2026 Generate an Info file from a Muse file.
2028 @cindex publishing styles, info-pdf
2029 @item info-pdf
2030 Publish a file in PDF form.
2032 @end table
2034 @subheading Options provided
2036 @table @code
2038 @item muse-texinfo-process-natively
2039 If non-nil, use the Emacs `texinfmt' module to make Info files.
2041 @item muse-texinfo-extension
2042 Default file extension for publishing Texinfo files.
2044 @item muse-texinfo-info-extension
2045 Default file extension for publishing Info files.
2047 @item muse-texinfo-pdf-extension
2048 Default file extension for publishing PDF files.
2050 @item muse-texinfo-header
2051 Text to prepend to a Muse page being published as Texinfo.
2053 This may be text or a filename.
2054 It may contain @verb{|<lisp>|} markup tags.
2056 @item muse-texinfo-footer
2057 Text to append to a Muse page being published as Texinfo.
2059 This may be text or a filename.
2060 It may contain @verb{|<lisp>|} markup tags.
2062 @item muse-texinfo-markup-regexps
2063 List of markup rules for publishing a Muse page to Texinfo.
2065 For more on the structure of this list,
2066 @xref{muse-publish-markup-regexps}.
2068 @item muse-texinfo-markup-functions
2069 An alist of style types to custom functions for that kind of text.
2071 For more on the structure of this list, see
2072 @xref{muse-publish-markup-functions}.
2074 @item muse-texinfo-markup-strings
2075 Strings used for marking up text.
2077 These cover the most basic kinds of markup, the handling of which
2078 differs little between the various styles.
2080 @item muse-texinfo-markup-specials
2081 A table of characters which must be represented specially.
2083 @end table
2086 @node Extending Muse, Getting Help and Reporting Bugs, Publishing Styles, Top
2087 @comment  node-name,  next,  previous,  up
2088 @chapter Making your own publishing styles
2090 @menu
2091 * Common Elements::             Common functionality shared by styles.
2092 * Deriving Styles::             Deriving a new style from an existing
2093                                   one.
2094 @end menu
2096 @node Common Elements, Deriving Styles, , Extending Muse
2097 @comment  node-name,  next,  previous,  up
2098 @section Common functionality shared by styles
2099 @cindex publishing styles, common
2101 @menu
2102 * Markup Functions::            Specifying functions to marking up text.
2103 * Markup Regexps::              Markup rules for publishing.
2104 * Markup Strings::              Strings specific to a publishing style.
2105 * Markup Tags::                 Tag specifications for special markup.
2106 * Style Elements::              Parameters used for defining styles.
2107 @end menu
2109 @node Markup Functions, Markup Regexps, , Common Elements
2110 @comment  node-name,  next,  previous,  up
2111 @subsection Specifying functions to mark up text
2112 @cindex publishing, markup functions
2114 @anchor{muse-publish-markup-functions}
2115 @code{muse-publish-markup-functions}
2117 An alist of style types to custom functions for that kind of text.
2119 This is used by publishing styles to attempt to minimize the amount of
2120 custom regexps that each has to define.  @file{muse-publish} provides
2121 rules for the most common types of markup.
2123 Each member of the list is of the following form.
2125 @example
2126 (SYMBOL FUNCTION)
2127 @end example
2129 @itemize @bullet
2130 @item SYMBOL
2131 Describes the type of text to associate with this rule.
2132 @code{muse-publish-markup-regexps} maps regexps to these symbols.
2134 @item FUNCTION
2135 Function to use to mark up this kind of rule if no suitable function is
2136 found through the @option{:functions} tag of the current style.
2137 @end itemize
2139 @node Markup Regexps, Markup Strings, Markup Functions, Common Elements
2140 @comment  node-name,  next,  previous,  up
2141 @subsection Markup rules for publishing
2142 @cindex publishing, markup regexps
2143 @cindex publishing, rules
2145 @anchor{muse-publish-markup-regexps}
2146 @code{muse-publish-markup-regexps}
2148 List of markup rules for publishing a page with Muse.
2150 The rules given in this variable are invoked first, followed by whatever
2151 rules are specified by the current style.
2153 Each member of the list is either a function, or a list of the following
2154 form.
2156 @example
2157 (REGEXP/SYMBOL TEXT-BEGIN-GROUP REPLACEMENT-TEXT/FUNCTION/SYMBOL)
2158 @end example
2160 @itemize @bullet
2161 @item REGEXP
2162 A regular expression, or symbol whose value is a regular expression,
2163 which is searched for using `re-search-forward'.
2165 @item TEXT-BEGIN-GROUP
2166 The matching group within that regexp which denotes the beginning of the
2167 actual text to be marked up.
2169 @item REPLACEMENT-TEXT
2170 A string that will be passed to `replace-match'.
2172 If it is not a string, but a function, it will be called to determine
2173 what the replacement text should be (it must return a string).  If it is
2174 a symbol, the value of that symbol should be a string.
2175 @end itemize
2177 The replacements are done in order, one rule at a time.  Writing
2178 the regular expressions can be a tricky business.  Note that case
2179 is never ignored.  `case-fold-search' is always bound to nil
2180 while processing the markup rules.
2182 @subheading Publishing order
2184 This is the order that the publishing rules are consulted, by default.
2185 This may be changed by customizing @code{muse-publish-markup-regexps}.
2187 @table @code
2189 @item trailing and leading whitespace
2190 Remove trailing and leading whitespace from a file.
2192 @item directive
2193 @samp{#directive}
2195 This is only recognized at the beginning of a file.
2197 @item tag
2198 @samp{<tag>}
2200 @item comment
2201 @samp{; comment}
2203 @item anchor
2204 @samp{#anchor}
2206 @item explicit links
2207 Prevent emphasis characters in explicit links from being marked up.
2209 Don't actually publish them here, just add a special no-emphasis text
2210 property.
2212 @item word
2213 Whitespace-delimited word, possibly with emphasis characters
2215 This function is responsible for marking up emphasis and escaping some
2216 specials.
2218 @item emdash
2219 @samp{--}
2221 2-wide dash
2223 @item heading
2224 @samp{** Heading}
2226 Outline-mode style headings.
2228 @item enddots
2229 @samp{....}
2231 These are ellipses with a dot at end.
2233 @item dots
2234 @samp{...}
2236 Ellipses.
2238 @item rule
2239 @samp{----}
2241 Horizontal rule or section separator.
2243 @item fn-sep
2244 @samp{Footnotes:}
2246 beginning of footnotes section
2248 @item footnote
2249 @samp{[1]}
2251 Footnote definition or reference.  If at beginning of line, it is a
2252 definition.
2254 @item list
2255 @itemize @bullet
2256 @item
2257 @samp{ 1. }
2259 @item
2260 @samp{ - }
2262 @item
2263 @samp{term :: }
2264 @end itemize
2266 Numbered list, item list, or term definition list.
2268 @item quote
2269 spaces before beginning of text
2271 Blockquotes.
2273 @item verse
2274 @samp{> verse text}
2276 @item table
2277 @samp{table | cells}
2279 @item link
2280 @samp{[[explicit][links]]}
2282 @item url
2283 @samp{http://example.com/}
2285 @item email
2286 @samp{bare-email@@example.com}
2288 @end table
2290 @node Markup Strings, Markup Tags, Markup Regexps, Common Elements
2291 @comment  node-name,  next,  previous,  up
2292 @subsection Strings specific to a publishing style
2293 @cindex publishing, markup strings
2295 @dfn{Markup strings} are strings used for marking up text for a
2296 particular style.
2298 These cover the most basic kinds of markup, the handling of which
2299 differs little between the various styles.
2301 @subheading Available markup strings
2303 @table @code
2305 @item image-with-desc
2306 An image and a description.
2308 Argument 1: image without extension.  Argument 2: image extension.
2309 Argument 3: description.
2311 @item image
2312 An inlined image.
2314 Argument 1: image without extension.  Argument 2: image extension.
2316 @item image-link
2317 A link to an image.
2319 Argument 1: link.  Argument 2: image without extension.
2320 Argument 3: image extension.
2322 @item anchor-ref
2323 A reference to an anchor on the current page.
2325 Argument 1: anchor name.  Argument 2: description if one exists, or the
2326 original link otherwise.
2328 @item url
2329 A URL without a description.
2331 Argument 1: URL.
2333 @item link
2334 A link with a description.
2336 Argument 1: link.  Argument 2: description if one exists, or the
2337 original link otherwise.
2339 @item link-and-anchor
2340 A link to a page with an anchor, and a description.
2342 Argument 1: link.  Argument 2: anchor name.
2343 Argument 3: description if one exists, or the original link otherwise.
2345 @item email-addr
2346 A link to an email address.
2348 Argument 1: email address.  Argument 2: email address.
2350 @item emdash
2351 A 2-length dash.
2353 Argument 1: Initial whitespace.  Argument 2: Terminating whitespace.
2355 @item comment-begin
2356 Beginning of a comment.
2358 @item comment-end
2359 End of a comment.
2361 @item rule
2362 A horizontal line or space.
2364 @item no-break-space
2365 A space that separates two words which are not to be separated.
2367 @item footnote
2368 Beginning of footnote.
2370 @item footnote-end
2371 End of footnote.
2373 @item footnotemark
2374 Mark a reference for the current footnote.
2376 Argument 1: number of this footnote.
2378 @item footnotemark-end
2379 End of a reference for the current footnote.
2381 @item footnotetext
2382 Indicate the text of the current footnote.
2384 Argument 1: number of this footnote.
2386 @item footnotetext-end
2387 End of a footnote text line.
2389 @item fn-sep
2390 Text used to replace ``Footnotes:'' line.
2392 @item dots
2393 3 dots.
2395 @item enddots
2396 4 dots.
2398 @item part
2399 Beginning of a part indicator line.  This is used by book publishing.
2401 @item part-end
2402 End of a part indicator line.  This is used by book publishing.
2404 @item chapter
2405 Beginning of a chapter indicator line.  This is used by book publishing.
2407 @item chapter-end
2408 End of a chapter indicator line.  This is used by book publishing.
2410 @item section
2411 Beginning of level 1 section indicator line.
2413 Argument 1: level of section; always 1.
2415 @item section-end
2416 End of level 1 section indicator line.
2418 Argument 1: level of section; always 1.
2420 @item subsection
2421 Beginning of level 2 section indicator line.
2423 Argument 1: level of section; always 2.
2425 @item subsection-end
2426 End of level 2 section indicator line.
2428 Argument 1: level of section; always 2.
2430 @item subsubsection
2431 Beginning of level 3 section indicator line.
2433 Argument 1: level of section; always 3.
2435 @item subsubsection-end
2436 End of level 3 section indicator line.
2438 Argument 1: level of section; always 3.
2440 @item section-other
2441 Beginning of section indicator line, where level is greater than 3.
2443 Argument 1: level of section.
2445 @item section-other-end
2446 Beginning of section indicator line, where level is greater than 3.
2448 Argument 1: level of section.
2450 @item begin-underline
2451 Beginning of underlined text.
2453 @item end-underline
2454 End of underlined text.
2456 @item begin-literal
2457 Beginning of verbatim text.  This includes @verb{|<code>|} tags and
2458 =teletype text=.
2460 @item end-literal
2461 End of verbatim text.  This includes @verb{|<code>|} tags and =teletype
2462 text=.
2464 @item begin-emph
2465 Beginning of the first level of emphasized text.
2467 @item end-emph
2468 End of the first level of emphasized text.
2470 @item begin-more-emph
2471 Beginning of the second level of emphasized text.
2473 @item end-more-emph
2474 End of the second level of emphasized text.
2476 @item begin-most-emph
2477 Beginning of the third (and final) level of emphasized text.
2479 @item end-most-emph
2480 End of the third (and final) level of emphasized text.
2482 @item begin-verse
2483 Beginning of verse text.
2485 @item verse-space
2486 String used to each space that is further indented than the beginning of
2487 the verse.
2489 @item begin-verse-line
2490 Beginning of a line of verse.
2492 @item empty-verse-line
2493 End of a line of verse.
2495 @item begin-last-stanza-line
2496 Beginning of the last line of a verse stanza.
2498 @item end-last-stanza-line
2499 End of the last line of a verse stanza.
2501 @item end-verse
2502 End of verse text.
2504 @item begin-example
2505 Beginning of an example region.  To make use of this, an
2506 @samp{<example>} tag is needed.
2508 @item end-example
2509 End of an example region.  To make use of this, an @samp{</example>} tag
2510 is needed.
2512 @item begin-center
2513 Begin a centered line.
2515 @item end-center
2516 End a centered line.
2518 @item begin-quote
2519 Begin a quoted region.
2521 @item end-quote
2522 End a quoted region.
2524 @item begin-uli
2525 Begin an unordered list.
2527 @item end-uli
2528 End an unordered list.
2530 @item begin-uli-item
2531 Begin an unordered list item.
2533 @item end-uli-item
2534 End an unordered list item.
2536 @item begin-oli
2537 Begin an ordered list.
2539 @item end-oli
2540 End an ordered list.
2542 @item begin-oli-item
2543 Begin an ordered list item.
2545 @item end-oli-item
2546 End an ordered list item.
2548 @item begin-dl
2549 Begin a definition list.
2551 @item end-dl
2552 End a definition list.
2554 @item begin-dl-item
2555 Begin a definition list item.
2557 @item end-dl-item
2558 End a definition list item.
2560 @item begin-ddt
2561 Begin a definition list term.
2563 @item end-ddt
2564 End a definition list term.
2566 @item begin-dde
2567 Begin a definition list entry.
2569 @item end-dde
2570 End a definition list entry.
2572 @item begin-table
2573 Begin a table.
2575 @item end-table
2576 End a table.
2578 @item begin-table-group
2579 Begin a table grouping.
2581 @item end-table-group
2582 End a table grouping.
2584 @item begin-table-row
2585 Begin a table row.
2587 @item end-table-row
2588 End a table row.
2590 @item begin-table-entry
2591 Begin a table entry.
2593 @item end-table-entry
2594 End a table entry.
2596 @end table
2598 @node Markup Tags, Style Elements, Markup Strings, Common Elements
2599 @comment  node-name,  next,  previous,  up
2600 @subsection Tag specifications for special markup
2601 @cindex publishing, markup tags
2603 @anchor{muse-publish-markup-tags}
2604 @code{muse-publish-markup-tags}
2606 A list of tag specifications, for specially marking up text.
2608 XML-style tags are the best way to add custom markup to Muse.  This is
2609 easily accomplished by customizing this list of markup tags.
2611 For each entry, the name of the tag is given, whether it expects a
2612 closing tag and/or an optional set of attributes, whether it is
2613 nestable, and a function that performs whatever action is desired within
2614 the delimited region.
2616 The tags themselves are deleted during publishing, before the function
2617 is called.  The function is called with three arguments, the beginning
2618 and end of the region surrounded by the tags.  If properties are
2619 allowed, they are passed as a third argument in the form of an alist.
2620 The `end' argument to the function is always a marker.
2622 Point is always at the beginning of the region within the tags, when the
2623 function is called.  Wherever point is when the function finishes is
2624 where tag markup will resume.
2626 These tag rules are processed once at the beginning of markup, and once
2627 at the end, to catch any tags which may have been inserted in-between.
2629 @node Style Elements, , Markup Tags, Common Elements
2630 @comment  node-name,  next,  previous,  up
2631 @subsection Parameters used for defining styles
2632 @cindex publishing, style elements
2634 Style elements are tags that define a style.  Use
2635 @code{muse-define-style} to create a new style.
2637 @example
2638 (muse-define-style DERIVED-NAME BASE-NAME STYLE-PARAMETERS)
2639 @end example
2641 @subheading Usable elements
2643 @table @option
2645 @item :suffix
2646 File extension to use for publishing files with this style.
2648 @item :link-suffix
2649 File extension to use for publishing links to Muse files with this
2650 style.
2652 @item :osuffix
2653 File extension to use for publishing second-stage files with this style.
2655 For example, PDF publishing generates a LaTeX file first, then a PDF
2656 from that LaTeX file.
2658 @item :regexps
2659 List of markup rules for publishing a page with Muse.
2660 @xref{muse-publish-markup-regexps}.
2662 @item :functions
2663 An alist of style types to custom functions for that kind of text.
2664 @xref{muse-publish-markup-functions}.
2666 @item :strings
2667 Strings used for marking up text with this style.
2669 These cover the most basic kinds of markup, the handling of which
2670 differs little between the various styles.
2672 @item :tags
2673 A list of tag specifications, used for handling extra tags.
2674 @xref{muse-publish-markup-tags}.
2676 @item :specials
2677 A table of characters which must be represented specially.
2679 @item :before
2680 A function that is to be executed on the newly-created publishing buffer
2681 (or the current region) before any publishing occurs.
2683 This is used to set extra parameters that direct the publishing process.
2685 @item :before-end
2686 A function that is to be executed on the publishing buffer (or the
2687 current region) immediately after applying all of the markup regexps.
2689 This is used to fix the order of table elements (header, footer, body)
2690 in XML-ish styles.
2692 @item :after
2693 A function that is to be executed on the publishing buffer after
2694 :before-end, and immediately after inserting the header and footer.
2696 This is used for generating the table of contents as well as setting the
2697 file coding system.
2699 @item :final
2700 A function that is to be executed after saving the published file, but
2701 while still in its buffer.
2703 This is used for generating second-stage documents like PDF files from
2704 just-published LaTeX files.
2706 @item :header
2707 Header used for publishing files of this style.
2709 This may be a variable, text, or a filename.  It is inserted at the
2710 beginning of a file, after evaluating the publishing markup.
2712 @item :footer
2713 Footer used for publishing files of this style.
2715 This may be a variable, text, or a filename.  It is inserted at the end
2716 of a file, after evaluating the publishing markup.
2718 @item :style-sheet
2719 Style sheet used for publishing files of this style.
2721 This may be a variable or text.  It is used in the header of HTML and
2722 XHTML based publishing styles.
2724 @item :browser
2725 The function used to browse the published result of files of this style.
2727 @end table
2729 @node Deriving Styles, , Common Elements, Extending Muse
2730 @comment  node-name,  next,  previous,  up
2731 @section Deriving a new style from an existing one
2732 @cindex publishing styles, deriving
2734 To create a new style from an existing one, use @code{muse-derive-style}
2735 as follows.  This is a good way to fix something you don't like about a
2736 particular publishing style, or to personalize it.
2738 @example
2739 (muse-derive-style DERIVED-NAME BASE-NAME STYLE-PARAMETERS)
2740 @end example
2742 The derived name is a string defining the new style, such as "my-html".
2743 The base name must identify an existing style, such as "html" -- if you
2744 have loaded @file{muse-html}.  The style parameters are the same as
2745 those used to create a style, except that they override whatever
2746 definitions exist in the base style.  However, some definitions only
2747 partially override.  The following parameters support partial
2748 overriding.
2750 @xref{Style Elements}, for a complete list of all parameters.
2752 @table @option
2754 @item :functions
2755 If a markup function is not found in the derived style's function list,
2756 the base style's function list will be queried.
2758 @item :regexps
2759 All regexps in the current style and the base style(s) will be used.
2761 @item :strings
2762 If a markup string is not found in the derived style's string list, the
2763 base style's string list will be queried.
2765 @end table
2768 @node Getting Help and Reporting Bugs, History, Extending Muse, Top
2769 @comment  node-name,  next,  previous,  up
2770 @chapter Getting Help and Reporting Bugs
2771 @cindex help, getting
2772 @cindex bugs, reporting
2774 After you have read this guide, if you still have questions about
2775 Muse, or if you have bugs to report, there are several places you can
2778 @itemize @bullet
2780 @item
2781 @uref{http://www.emacswiki.org/cgi-bin/wiki/MuseMode} is the
2782 emacswiki.org page, and anyone may add tips, hints, or bug descriptions
2783 to it.
2785 @item
2786 @uref{http://www.mwolson.org/projects/EmacsMuse.html} is the web page
2787 that Michael Olson (the current maintainer) made for Muse.
2789 @item
2790 Muse has four mailing lists.
2792 @table @samp
2794 @item muse-el-announce
2795 Low-traffic list for Muse-related announcements.
2797 You can join this mailing list (@email{muse-el-announce@@gna.org})
2798 using the subscription form at
2799 @url{http://mail.gna.org/listinfo/muse-el-announce/}.  This
2800 mailing list is also available via Gmane (@url{http://gmane.org/}). The
2801 group is called @samp{gmane.emacs.muse.announce}.
2803 @item muse-el-discuss
2804 Discussion, bugfixes, suggestions, tips, and the like for Muse.
2805 This mailing list also includes the content of muse-el-announce.
2807 You can join this mailing list (@email{muse-el-discuss@@gna.org})
2808 using the subscription form at
2809 @url{http://mail.gna.org/listinfo/muse-el-discuss/}.  This mailing
2810 list is also available via Gmane with the identifier
2811 @samp{gmane.emacs.muse.general}.
2813 @item muse-el-commits
2814 Log messages for changes committed to Muse.
2816 You can join this mailing list (@email{muse-el-commits@@gna.org}) using
2817 the subscription form at
2818 @url{http://mail.gna.org/listinfo/muse-el-commits/}.  This mailing list
2819 is also available via Gmane with the identifier
2820 @samp{gmane.emacs.muse.cvs}.
2822 @item muse-el-internationalization
2823 Discussion of translation of the Muse website and documentation into
2824 many languages.
2826 You can join this mailing list
2827 (@email{muse-el-internationalization@@gna.org}) using the subscription
2828 form at @url{http://mail.gna.org/listinfo/internationalization/}.  This
2829 mailing list is also available via Gmane with the identifier
2830 @samp{gmane.emacs.muse.internationalization}.
2832 @end table
2834 @item
2835 You can visit the IRC Freenode channel @samp{#emacs}. Many of the
2836 contributors are frequently around and willing to answer your
2837 questions.  The @samp{#muse} channel is also available for
2838 Muse-specific help, and its current maintainer hangs out there.
2840 @item
2841 The maintainer of Emacs Muse, Michael Olson, may be contacted at
2842 @email{mwolson@@gnu.org}.  He can be rather slow at answering email, so
2843 it is often better to use the muse-el-discuss mailing list.
2845 @end itemize
2847 @node History, Contributors, Getting Help and Reporting Bugs, Top
2848 @comment  node-name,  next,  previous,  up
2849 @chapter History of This Document
2850 @cindex history, of Muse
2852 @itemize
2853 @item 2004
2854 John Wiegley started Muse upon realizing that EmacsWiki had some serious
2855 limitations. Around February 2004, he started making "emacs-wiki version
2856 3.00 APLHA", which eventually became known as Muse.
2858 Most of those who frequent the emacs-wiki mailing list continued to use
2859 emacs-wiki, mainly because Planner hasn't been ported over to it.
2861 As of 2004-12-01, Michael Olson became the maintainer of Muse, as per
2862 John Wiegley's request.
2864 @item 2005
2865 Michael Olson overhauled this document and added many new sections in
2866 preparation for the first release of Muse (3.01).
2868 @end itemize
2870 @node Contributors, GNU General Public License, History, Top
2871 @comment  node-name,  next,  previous,  up
2872 @chapter Contributors to This Documentation
2873 @cindex contributors
2875 The first draft of this document was taken from the emacs-wiki texinfo
2876 manual.  Michael Olson adapted it for Muse and added most of its
2877 content.
2879 John Sullivan did a majority of the work on the emacs-wiki texinfo
2880 manual.
2882 While Sacha Chua maintained emacs-wiki, she worked quite a bit on the
2883 emacs-wiki texinfo manual.
2885 @node GNU General Public License, Concept Index, Contributors, Top
2886 @comment  node-name,  next,  previous,  up
2887 @appendix GNU GENERAL PUBLIC LICENSE
2888 @center Version 2, June 1991
2889 @cindex GPL
2890 @cindex GNU General Public License
2892 @c This file is intended to be included in another file.
2894 @display
2895 Copyright @copyright{} 1989, 1991 Free Software Foundation, Inc.
2896 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
2898 Everyone is permitted to copy and distribute verbatim copies
2899 of this license document, but changing it is not allowed.
2900 @end display
2902 @appendixsec Preamble
2904   The licenses for most software are designed to take away your
2905 freedom to share and change it.  By contrast, the GNU General Public
2906 License is intended to guarantee your freedom to share and change free
2907 software---to make sure the software is free for all its users.  This
2908 General Public License applies to most of the Free Software
2909 Foundation's software and to any other program whose authors commit to
2910 using it.  (Some other Free Software Foundation software is covered by
2911 the GNU Library General Public License instead.)  You can apply it to
2912 your programs, too.
2914   When we speak of free software, we are referring to freedom, not
2915 price.  Our General Public Licenses are designed to make sure that you
2916 have the freedom to distribute copies of free software (and charge for
2917 this service if you wish), that you receive source code or can get it
2918 if you want it, that you can change the software or use pieces of it
2919 in new free programs; and that you know you can do these things.
2921   To protect your rights, we need to make restrictions that forbid
2922 anyone to deny you these rights or to ask you to surrender the rights.
2923 These restrictions translate to certain responsibilities for you if you
2924 distribute copies of the software, or if you modify it.
2926   For example, if you distribute copies of such a program, whether
2927 gratis or for a fee, you must give the recipients all the rights that
2928 you have.  You must make sure that they, too, receive or can get the
2929 source code.  And you must show them these terms so they know their
2930 rights.
2932   We protect your rights with two steps: (1) copyright the software, and
2933 (2) offer you this license which gives you legal permission to copy,
2934 distribute and/or modify the software.
2936   Also, for each author's protection and ours, we want to make certain
2937 that everyone understands that there is no warranty for this free
2938 software.  If the software is modified by someone else and passed on, we
2939 want its recipients to know that what they have is not the original, so
2940 that any problems introduced by others will not reflect on the original
2941 authors' reputations.
2943   Finally, any free program is threatened constantly by software
2944 patents.  We wish to avoid the danger that redistributors of a free
2945 program will individually obtain patent licenses, in effect making the
2946 program proprietary.  To prevent this, we have made it clear that any
2947 patent must be licensed for everyone's free use or not licensed at all.
2949   The precise terms and conditions for copying, distribution and
2950 modification follow.
2952 @iftex
2953 @appendixsec TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
2954 @end iftex
2955 @ifinfo
2956 @center TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
2957 @end ifinfo
2959 @enumerate 0
2960 @item
2961 This License applies to any program or other work which contains
2962 a notice placed by the copyright holder saying it may be distributed
2963 under the terms of this General Public License.  The ``Program'', below,
2964 refers to any such program or work, and a ``work based on the Program''
2965 means either the Program or any derivative work under copyright law:
2966 that is to say, a work containing the Program or a portion of it,
2967 either verbatim or with modifications and/or translated into another
2968 language.  (Hereinafter, translation is included without limitation in
2969 the term ``modification''.)  Each licensee is addressed as ``you''.
2971 Activities other than copying, distribution and modification are not
2972 covered by this License; they are outside its scope.  The act of
2973 running the Program is not restricted, and the output from the Program
2974 is covered only if its contents constitute a work based on the
2975 Program (independent of having been made by running the Program).
2976 Whether that is true depends on what the Program does.
2978 @item
2979 You may copy and distribute verbatim copies of the Program's
2980 source code as you receive it, in any medium, provided that you
2981 conspicuously and appropriately publish on each copy an appropriate
2982 copyright notice and disclaimer of warranty; keep intact all the
2983 notices that refer to this License and to the absence of any warranty;
2984 and give any other recipients of the Program a copy of this License
2985 along with the Program.
2987 You may charge a fee for the physical act of transferring a copy, and
2988 you may at your option offer warranty protection in exchange for a fee.
2990 @item
2991 You may modify your copy or copies of the Program or any portion
2992 of it, thus forming a work based on the Program, and copy and
2993 distribute such modifications or work under the terms of Section 1
2994 above, provided that you also meet all of these conditions:
2996 @enumerate a
2997 @item
2998 You must cause the modified files to carry prominent notices
2999 stating that you changed the files and the date of any change.
3001 @item
3002 You must cause any work that you distribute or publish, that in
3003 whole or in part contains or is derived from the Program or any
3004 part thereof, to be licensed as a whole at no charge to all third
3005 parties under the terms of this License.
3007 @item
3008 If the modified program normally reads commands interactively
3009 when run, you must cause it, when started running for such
3010 interactive use in the most ordinary way, to print or display an
3011 announcement including an appropriate copyright notice and a
3012 notice that there is no warranty (or else, saying that you provide
3013 a warranty) and that users may redistribute the program under
3014 these conditions, and telling the user how to view a copy of this
3015 License.  (Exception: if the Program itself is interactive but
3016 does not normally print such an announcement, your work based on
3017 the Program is not required to print an announcement.)
3018 @end enumerate
3020 These requirements apply to the modified work as a whole.  If
3021 identifiable sections of that work are not derived from the Program,
3022 and can be reasonably considered independent and separate works in
3023 themselves, then this License, and its terms, do not apply to those
3024 sections when you distribute them as separate works.  But when you
3025 distribute the same sections as part of a whole which is a work based
3026 on the Program, the distribution of the whole must be on the terms of
3027 this License, whose permissions for other licensees extend to the
3028 entire whole, and thus to each and every part regardless of who wrote it.
3030 Thus, it is not the intent of this section to claim rights or contest
3031 your rights to work written entirely by you; rather, the intent is to
3032 exercise the right to control the distribution of derivative or
3033 collective works based on the Program.
3035 In addition, mere aggregation of another work not based on the Program
3036 with the Program (or with a work based on the Program) on a volume of
3037 a storage or distribution medium does not bring the other work under
3038 the scope of this License.
3040 @item
3041 You may copy and distribute the Program (or a work based on it,
3042 under Section 2) in object code or executable form under the terms of
3043 Sections 1 and 2 above provided that you also do one of the following:
3045 @enumerate a
3046 @item
3047 Accompany it with the complete corresponding machine-readable
3048 source code, which must be distributed under the terms of Sections
3049 1 and 2 above on a medium customarily used for software interchange; or,
3051 @item
3052 Accompany it with a written offer, valid for at least three
3053 years, to give any third party, for a charge no more than your
3054 cost of physically performing source distribution, a complete
3055 machine-readable copy of the corresponding source code, to be
3056 distributed under the terms of Sections 1 and 2 above on a medium
3057 customarily used for software interchange; or,
3059 @item
3060 Accompany it with the information you received as to the offer
3061 to distribute corresponding source code.  (This alternative is
3062 allowed only for noncommercial distribution and only if you
3063 received the program in object code or executable form with such
3064 an offer, in accord with Subsection b above.)
3065 @end enumerate
3067 The source code for a work means the preferred form of the work for
3068 making modifications to it.  For an executable work, complete source
3069 code means all the source code for all modules it contains, plus any
3070 associated interface definition files, plus the scripts used to
3071 control compilation and installation of the executable.  However, as a
3072 special exception, the source code distributed need not include
3073 anything that is normally distributed (in either source or binary
3074 form) with the major components (compiler, kernel, and so on) of the
3075 operating system on which the executable runs, unless that component
3076 itself accompanies the executable.
3078 If distribution of executable or object code is made by offering
3079 access to copy from a designated place, then offering equivalent
3080 access to copy the source code from the same place counts as
3081 distribution of the source code, even though third parties are not
3082 compelled to copy the source along with the object code.
3084 @item
3085 You may not copy, modify, sublicense, or distribute the Program
3086 except as expressly provided under this License.  Any attempt
3087 otherwise to copy, modify, sublicense or distribute the Program is
3088 void, and will automatically terminate your rights under this License.
3089 However, parties who have received copies, or rights, from you under
3090 this License will not have their licenses terminated so long as such
3091 parties remain in full compliance.
3093 @item
3094 You are not required to accept this License, since you have not
3095 signed it.  However, nothing else grants you permission to modify or
3096 distribute the Program or its derivative works.  These actions are
3097 prohibited by law if you do not accept this License.  Therefore, by
3098 modifying or distributing the Program (or any work based on the
3099 Program), you indicate your acceptance of this License to do so, and
3100 all its terms and conditions for copying, distributing or modifying
3101 the Program or works based on it.
3103 @item
3104 Each time you redistribute the Program (or any work based on the
3105 Program), the recipient automatically receives a license from the
3106 original licensor to copy, distribute or modify the Program subject to
3107 these terms and conditions.  You may not impose any further
3108 restrictions on the recipients' exercise of the rights granted herein.
3109 You are not responsible for enforcing compliance by third parties to
3110 this License.
3112 @item
3113 If, as a consequence of a court judgment or allegation of patent
3114 infringement or for any other reason (not limited to patent issues),
3115 conditions are imposed on you (whether by court order, agreement or
3116 otherwise) that contradict the conditions of this License, they do not
3117 excuse you from the conditions of this License.  If you cannot
3118 distribute so as to satisfy simultaneously your obligations under this
3119 License and any other pertinent obligations, then as a consequence you
3120 may not distribute the Program at all.  For example, if a patent
3121 license would not permit royalty-free redistribution of the Program by
3122 all those who receive copies directly or indirectly through you, then
3123 the only way you could satisfy both it and this License would be to
3124 refrain entirely from distribution of the Program.
3126 If any portion of this section is held invalid or unenforceable under
3127 any particular circumstance, the balance of the section is intended to
3128 apply and the section as a whole is intended to apply in other
3129 circumstances.
3131 It is not the purpose of this section to induce you to infringe any
3132 patents or other property right claims or to contest validity of any
3133 such claims; this section has the sole purpose of protecting the
3134 integrity of the free software distribution system, which is
3135 implemented by public license practices.  Many people have made
3136 generous contributions to the wide range of software distributed
3137 through that system in reliance on consistent application of that
3138 system; it is up to the author/donor to decide if he or she is willing
3139 to distribute software through any other system and a licensee cannot
3140 impose that choice.
3142 This section is intended to make thoroughly clear what is believed to
3143 be a consequence of the rest of this License.
3145 @item
3146 If the distribution and/or use of the Program is restricted in
3147 certain countries either by patents or by copyrighted interfaces, the
3148 original copyright holder who places the Program under this License
3149 may add an explicit geographical distribution limitation excluding
3150 those countries, so that distribution is permitted only in or among
3151 countries not thus excluded.  In such case, this License incorporates
3152 the limitation as if written in the body of this License.
3154 @item
3155 The Free Software Foundation may publish revised and/or new versions
3156 of the General Public License from time to time.  Such new versions will
3157 be similar in spirit to the present version, but may differ in detail to
3158 address new problems or concerns.
3160 Each version is given a distinguishing version number.  If the Program
3161 specifies a version number of this License which applies to it and ``any
3162 later version'', you have the option of following the terms and conditions
3163 either of that version or of any later version published by the Free
3164 Software Foundation.  If the Program does not specify a version number of
3165 this License, you may choose any version ever published by the Free Software
3166 Foundation.
3168 @item
3169 If you wish to incorporate parts of the Program into other free
3170 programs whose distribution conditions are different, write to the author
3171 to ask for permission.  For software which is copyrighted by the Free
3172 Software Foundation, write to the Free Software Foundation; we sometimes
3173 make exceptions for this.  Our decision will be guided by the two goals
3174 of preserving the free status of all derivatives of our free software and
3175 of promoting the sharing and reuse of software generally.
3177 @iftex
3178 @heading NO WARRANTY
3179 @end iftex
3180 @ifinfo
3181 @center NO WARRANTY
3182 @end ifinfo
3184 @item
3185 BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
3186 FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN
3187 OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
3188 PROVIDE THE PROGRAM ``AS IS'' WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
3189 OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
3190 MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  THE ENTIRE RISK AS
3191 TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.  SHOULD THE
3192 PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
3193 REPAIR OR CORRECTION.
3195 @item
3196 IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
3197 WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
3198 REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
3199 INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
3200 OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
3201 TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
3202 YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
3203 PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
3204 POSSIBILITY OF SUCH DAMAGES.
3205 @end enumerate
3207 @iftex
3208 @heading END OF TERMS AND CONDITIONS
3209 @end iftex
3210 @ifinfo
3211 @center END OF TERMS AND CONDITIONS
3212 @end ifinfo
3214 @page
3215 @appendixsec Appendix: How to Apply These Terms to Your New Programs
3217   If you develop a new program, and you want it to be of the greatest
3218 possible use to the public, the best way to achieve this is to make it
3219 free software which everyone can redistribute and change under these terms.
3221   To do so, attach the following notices to the program.  It is safest
3222 to attach them to the start of each source file to most effectively
3223 convey the exclusion of warranty; and each file should have at least
3224 the ``copyright'' line and a pointer to where the full notice is found.
3226 @smallexample
3227 @var{one line to give the program's name and a brief idea of what it does.}
3228 Copyright (C) @var{yyyy}  @var{name of author}
3230 This program is free software; you can redistribute it and/or modify
3231 it under the terms of the GNU General Public License as published by
3232 the Free Software Foundation; either version 2 of the License, or
3233 (at your option) any later version.
3235 This program is distributed in the hope that it will be useful,
3236 but WITHOUT ANY WARRANTY; without even the implied warranty of
3237 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
3238 GNU General Public License for more details.
3240 You should have received a copy of the GNU General Public License along
3241 with this program; if not, write to the Free Software Foundation, Inc.,
3242 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
3243 @end smallexample
3245 Also add information on how to contact you by electronic and paper mail.
3247 If the program is interactive, make it output a short notice like this
3248 when it starts in an interactive mode:
3250 @smallexample
3251 Gnomovision version 69, Copyright (C) 19@var{yy} @var{name of author}
3252 Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
3253 This is free software, and you are welcome to redistribute it
3254 under certain conditions; type `show c' for details.
3255 @end smallexample
3257 The hypothetical commands @samp{show w} and @samp{show c} should show
3258 the appropriate parts of the General Public License.  Of course, the
3259 commands you use may be called something other than @samp{show w} and
3260 @samp{show c}; they could even be mouse-clicks or menu items---whatever
3261 suits your program.
3263 You should also get your employer (if you work as a programmer) or your
3264 school, if any, to sign a ``copyright disclaimer'' for the program, if
3265 necessary.  Here is a sample; alter the names:
3267 @example
3268 Yoyodyne, Inc., hereby disclaims all copyright interest in the program
3269 `Gnomovision' (which makes passes at compilers) written by James Hacker.
3271 @var{signature of Ty Coon}, 1 April 1989
3272 Ty Coon, President of Vice
3273 @end example
3275 This General Public License does not permit incorporating your program into
3276 proprietary programs.  If your program is a subroutine library, you may
3277 consider it more useful to permit linking proprietary applications with the
3278 library.  If this is what you want to do, use the GNU Library General
3279 Public License instead of this License.
3282 @node Concept Index,  , GNU General Public License, Top
3283 @comment  node-name,  next,  previous,  up
3284 @unnumbered Index
3286 @printindex cp
3288 @bye