[odf-discuss] A Pit Bull in the Mix

Matthew Cruickshank odf-fellowship at holloway.co.nz
Wed May 30 00:43:51 EDT 2007


Daniel wrote:
>   Headings:
>     <h1> ... </h1>
>     Becomes...
>     <text:h text:style-name="Heading_20_1"> ... </text:h>
>

You'd probably want @text:outline-level in there too, to express level 1.

Damon Anderson wrote:
> very nice simplification. Now that I can use. DocBook also too 
> complicated a spec to readily implement. Just trying to get through 
> the DTD chapters that start out the spec is like pulling teeth.
>
> So, how would you implement sections in your 30 second tutorial?

DocBook does have a lot of tags, and initially it's hard to tell what a
user-friendly subset would even look like. Here's a print-out I've got
on the wall here to remind me of the basics (may or may not validate)...

<?xml version="1.0"?>
<book xmlns="http://docbook.org/ns/docbook">
    <preface>
        <title> ... </title>
        <para> ... </para>
    </preface>
    <chapter>
        <title> ... </title>
        <para> ...
            <emphasis role="bold"> ... </emphasis>
            <literal role="linebreak">&#10;</literal>
            <mediaobject>
                <imageobject><imagedata fileref="something.jpg"
format="jpg"/></imageobject>
            </mediaobject>
            <link xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:href="http://docbook.org"> docbook </link>
        </para>
        <itemizedlist>
            <listitem>
                <para> ... </para>
            </listitem>
            ...
        </itemizedlist>
        <orderedlist>
            <listitem>
                <para> ... </para>
            </listitem>
            ...
        <orderedlist>
        <table>
            <thead>
                <row><entry> ... </entry><entry> ... </entry></row>
            </thead>
            <tbody>
                <row><entry><para> ... </para></entry><entry><para> ...
</para></entry></row>
                <row><entry><para> ... </para></entry><entry><para> ...
</para></entry></row>
            </tbody>
        </table>
        <sect1>
            <title> ... </title>
            <para> ... </para>
            <sect2>
                <title> ... </title>
                <para> ... </para>
            </sect>
            <sect2>
                <title> ... </title>
                <para> ... </para>
            </sect>
        </sect1>
    </chapter>
    <chapter>
        ...
    </chapter>
</book>



.Matthew Cruickshank
http://docvert.org << Microsoft Word to Open Standards



More information about the odf-discuss mailing list