From f8ae3f39255a1c31c8ab13c8f1d38ee7318ce11b Mon Sep 17 00:00:00 2001 From: panne Date: Mon, 16 Aug 2004 19:59:53 +0000 Subject: [PATCH] [project @ 2004-08-16 19:59:28 by panne] XMLification --- docs/docbook-cheat-sheet/Makefile | 4 +- docs/docbook-cheat-sheet/docbook-cheat-sheet.sgml | 208 ------------------- docs/docbook-cheat-sheet/docbook-cheat-sheet.xml | 223 +++++++++++++++++++++ 3 files changed, 225 insertions(+), 210 deletions(-) delete mode 100644 docs/docbook-cheat-sheet/docbook-cheat-sheet.sgml create mode 100644 docs/docbook-cheat-sheet/docbook-cheat-sheet.xml diff --git a/docs/docbook-cheat-sheet/Makefile b/docs/docbook-cheat-sheet/Makefile index 16420de..95896d1 100644 --- a/docs/docbook-cheat-sheet/Makefile +++ b/docs/docbook-cheat-sheet/Makefile @@ -1,7 +1,7 @@ TOP = ../.. include $(TOP)/mk/boilerplate.mk -SGML_DOC = docbook-cheat-sheet -INSTALL_SGML_DOC = docbook-cheat-sheet +XML_DOC = docbook-cheat-sheet +INSTALL_XML_DOC = docbook-cheat-sheet include $(TOP)/mk/target.mk diff --git a/docs/docbook-cheat-sheet/docbook-cheat-sheet.sgml b/docs/docbook-cheat-sheet/docbook-cheat-sheet.sgml deleted file mode 100644 index c2a87f5..0000000 --- a/docs/docbook-cheat-sheet/docbook-cheat-sheet.sgml +++ /dev/null @@ -1,208 +0,0 @@ - - -
- - - -Using DocBook to write GHC documentation -The GHC Team -
glasgow-haskell-{users,bugs}@dcs.gla.ac.uk
-January 2000 - -
- - -Getting the DocBook tools - - -See the installation guide. - - - - - -Document layout - - -The GHC documentation is written using DocBook 3.1, so the DTD line should be: - - - -<!DOCTYPE Article PUBLIC "-//OASIS//DTD DocBook V3.1//EN"> - - - This guide is not meant to teach you how to -write DocBook; read the DocBook -book for that. It is more of a reference than a tutorial, so see the -DocBook home page -for other links. - - However, by popular demand, here are some useful points: - - - -Remember to use Para inside -ListItems. - - - - - The rest of this section outlines the use of several tags which may -not be obvious (DocBook is rather scholastic in style: it has tags for many -things from C function prototypes to keyboard bindings; at the same time it -has many omissions and oddities). The current scheme has many infelicities, -partly because it was dreamt up in a hurry while the author was learning -DocBook and converting the documentation thereto, and partly because DocBook -is rather C-centric. - - - -Comments - - -Comments in SGML look like this: This is a -comment. - - - - -Command - - -Used for commands typed into interactive sessions (e.g. cp foo bar and the names of programs such as gmake. - - - - -Constant - - -Used for system constants such as U_MAXINT and Makefile variables like SRC_FILES (because they are usually constant for a given run of make, and hence have a constant feel to them). - - - - -Email - - -For email addresses. This is a tag that's easy to overlook if you don't know it's there. - - - - -Filename - - -Used for paths, filenames, file extensions. - - - - -Function - - -Used for functions and constructors. - - - - -IndexTerm - - -The normal way to mark up an index term is <IndexTerm><Primary>term</Primary></IndexTerm>. - - - - -KeyCapKeyCombo - - -Some more tags you may miss. Used for combinations such as ControlD. - - - - -Literal - - -Used for everything that should appear in typewriter font that has no other obvious tag: types, monads, small snippets of program text that are formatted inline, and the like. - - - - -Option - - -Used for compiler options and similar. - - - - -ProgramListing - - -For displayed program listings (including shell scripts). - - - - -Screen - - -For displayed screen dumps, such as portions of shell interaction. It's easy to tell the difference between these and shell scripts: the latter lack a shell prompt. - - - - -VarName - - -Used for variables, but not type variables. - - - - - - - - -Tables - - -Tables are quite complicated to write in SGML (as in HTML, there are lots of fiddly tags), so here's an example you can cannibalise. In the spirit of the LaTeX short introduction I don't repeat all the markup verbatim; you have to look at the source for that. - - - - - - - - - - - -Here's -a sample -table - - - -With differently -aligned -cells - - - - -There's not much else to it. Entries can span both extra rows and extra columns; just be careful when using block markup (such as Paras) within an Entry that there is no space between the open and close Entry tags and the adjacent text, as otherwise you will suffer from Pernicious Mixed Content (the parser will think you're using inline markup). - - - - - - - - - - -
diff --git a/docs/docbook-cheat-sheet/docbook-cheat-sheet.xml b/docs/docbook-cheat-sheet/docbook-cheat-sheet.xml new file mode 100644 index 0000000..7f76339 --- /dev/null +++ b/docs/docbook-cheat-sheet/docbook-cheat-sheet.xml @@ -0,0 +1,223 @@ + + + +
+ + + Using DocBook to write GHC documentation + The GHC Team +
glasgow-haskell-{users,bugs}@dcs.gla.ac.uk
+ January 2000 +
+ + + Getting the DocBook tools + See the installation guide. + + + + Document layout + + The GHC documentation is written using DocBook XML V4.2, so + the first few lines should look like this: + + +<?xml version="1.0" encoding="iso-8859-1"?> +<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" + "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"> + + + The encoding can of course be chosen according to taste. + + This guide is not meant to teach you + how to write DocBook; read the DocBook book for that. It is + more of a reference than a tutorial, so see the DocBook home page + for other links. + + However, by popular demand, here are some useful points: + + + + + Remember to use para + inside listitems. + + + + The rest of this section outlines the use of several tags + which may not be obvious (DocBook is rather scholastic in style: + it has tags for many things from C function prototypes to keyboard + bindings; at the same time it has many omissions and + oddities). The current scheme has many infelicities, partly + because it was dreamt up in a hurry while the author was learning + DocBook and converting the documentation thereto, and partly + because DocBook is rather C-centric. + + + + + Comments + + Comments in SGML look like this: This is a comment. + + + + + command + + Used for commands typed into interactive sessions + (e.g. cp foo bar and the names of + programs such as gmake. + + + + + constant + + Used for system constants such as + U_MAXINT and + Makefile variables like + SRC_FILES (because they are usually + constant for a given run of make, and + hence have a constant feel to them). + + + + + email + + For email addresses. This is a tag that's easy to + overlook if you don't know it's there. + + + + + filename + + Used for paths, filenames, file extensions. + + + + + function + + Used for functions and constructors. + + + + + indexterm + + The normal way to mark up an index term is + <indexterm><primary>term</primary></indexterm>. + + + + + keycap + keycombo + + Some more tags you may miss. Used for combinations + such as + ControlD. + + + + + literal + + Used for everything that should appear in typewriter + font that has no other obvious tag: types, monads, small + snippets of program text that are formatted inline, and the + like. + + + + + option + + Used for compiler options and similar. + + + + + programlisting + + For displayed program listings (including shell + scripts). + + + + + screen + + For displayed screen dumps, such as portions of shell + interaction. It's easy to tell the difference between these + and shell scripts: the latter lack a shell prompt. + + + + + varname + + Used for variables, but not type variables. + + + + + + + + + Tables + + Tables are quite complicated to write in SGML (as in HTML, + there are lots of fiddly tags), so here's an example you can + cannibalise. In the spirit of the LaTeX short introduction I don't + repeat all the markup verbatim; you have to look at the source for + that. + + + + + + + + + + Here's + a sample + table + + + + With differently + aligned + cells + + + + + There's not much else to it. Entries can span + both extra rows and extra columns; just be careful when + using block markup (such as paras) within an entry that there is no space + between the open and close entry tags and the adjacent + text, as otherwise you will suffer from Pernicious + Mixed Content (the parser will think you're + using inline markup). + + + + + + + +
-- 1.7.10.4