From: arjen Date: Tue, 19 Aug 2003 06:34:43 +0000 (+0000) Subject: Added element for description lists X-Git-Tag: V0_5~2 X-Git-Url: http://www.andromeda.nl/gitweb/?p=xmldoc.git;a=commitdiff_plain;h=26dd345efa8d21e7d5269f148a9b65cb8f647485 Added element for description lists Added table example --- diff --git a/doc/block.xml b/doc/block.xml index 36a593e..b102fed 100644 --- a/doc/block.xml +++ b/doc/block.xml @@ -5,7 +5,7 @@ @@ -87,7 +87,7 @@ Which comes out like this:
-Footnotes + Footnotes are created with the footnote element: This is an example of a footnote @@ -111,17 +111,18 @@ running text referring to that footnote.
-Lists + -Two types of listsA description list is not implemented yet are supported: +Three types of lists are supported: itemize for bulleted lists such as this one. enumerate for numbered lists. +description for tagged lists. -Each item in such a list must be in an item element. -In fact, an item is the only element allowed in an -itemize or enumerate element. +Each item in such a list must be in an item element. +In fact, an item is the only element allowed in an +itemize, enumerate or description element. You should not put ordinary text or any other element in a list without enclosing them in <item> and </item>. Here is an example of a numbered list: @@ -139,16 +140,39 @@ Here is an example of a numbered list: And this is what the list turns into: - First you need an enumerate or itemize tag. + First you need an enumerate, itemize or description tag. Second, include one or more item elements. Finally, put the content inside the items. +In a description list, you make your own tags for each item instead +of the automatically generated bullts or numbers. +The tags for each item go in the tag attribute of the +item element. +So, repeating the above list as a description list: + + +<description> + <item tag='itemize'> for bulleted lists such as this one.</item> + <item tag='enumerate'> for numbered lists.</item> + <item tag='description'> for tagged lists.</item> +</description> + + +Which creates the following output: + + + for bulleted lists. + for numbered lists. + for tagged lists such as this one. + + +An item can contain inline content as well as block-level content.
-Including graphics + The empty element picture is used to include graphics in your document, like this: @@ -162,20 +186,41 @@ The two attributes are used in either HTML or LaTeX.
-Tables + Creating tables in XMLDoc is much like creating tables in HTML. -First, there is the table element. -The table element may contain any number of -row elements, which may in turn contain any number -of col elements. -The col elements hold the actual content of -the table, which must be inline content (see next chapter). -To use the tables in LaTeX, you must supply a cpos -attribute in the table tag. - -...tune in next week for a table example... +First, there is the table element. +The table element may contain an optional thead +and any number of row elements. +Both the thead and the row elements must contain +one or more col elements. +The col elements hold the actual content of +the table, which must be inline content (see next chapter) or block content. +To use the tables in LaTeX, you must supply a cpos +attribute in the table tag. + + +An example of a table is shown below: + + + +<table cpos='lr'> + <thead><col>Drink </col><col>Price</col></thead> + <row><col>Beer </col><col> 1.80</col></row> + <row><col>Wiskey </col><col> 3.50</col></row> + <row><col>Wine </col><col> 2.20</col></row> +</table> + + + + + Drink Price + Beer 1.80 + Wiskey 3.50 + Wine 2.20 +
+