Return-Path: X-Original-To: apmail-incubator-ooo-commits-archive@minotaur.apache.org Delivered-To: apmail-incubator-ooo-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 836027FDC for ; Tue, 29 Nov 2011 21:38:56 +0000 (UTC) Received: (qmail 22932 invoked by uid 500); 29 Nov 2011 21:38:56 -0000 Delivered-To: apmail-incubator-ooo-commits-archive@incubator.apache.org Received: (qmail 22874 invoked by uid 500); 29 Nov 2011 21:38:56 -0000 Mailing-List: contact ooo-commits-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: ooo-dev@incubator.apache.org Delivered-To: mailing list ooo-commits@incubator.apache.org Received: (qmail 22867 invoked by uid 99); 29 Nov 2011 21:38:56 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 29 Nov 2011 21:38:56 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 29 Nov 2011 21:38:50 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 3F0662388978; Tue, 29 Nov 2011 21:38:30 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1208093 [2/6] - in /incubator/ooo/ooo-site/trunk/content/xml/xmerge: ./ docbook/ docbook/images/ docs/ downloads/ plugins/ plugins/images/ Date: Tue, 29 Nov 2011 21:38:13 -0000 To: ooo-commits@incubator.apache.org From: kschenk@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20111129213830.3F0662388978@eris.apache.org> Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/supported_tag_table.html URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/supported_tag_table.html?rev=1208093&view=auto ============================================================================== --- incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/supported_tag_table.html (added) +++ incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/supported_tag_table.html Tue Nov 29 21:37:58 2011 @@ -0,0 +1,1156 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
DocBook CategoriesTag NameImportRound TripOOorg Mapping
General<abstract>XXIn-Line
Personal Information<address>XXIn-Line
Personal Information<affiliation>XXIn-Line
Component<appendix>XXTop-Level Element
Operating Environment<application>XXIn-Line
Meta Information<articleinfo>XXMeta Information
Component<article>XXTop-Level Element
Author<author>XXIn-Line
Author<authorblurb>

In-Line
Author<authorgroup>XXNested Element
Top Level<book>

Top-Level Element
Meta Information<bookinfo>

Meta Information
In Line<caption>XXIn-Line
Component<chapter>XXTop-Level Element
Meta Information<chapterinfo>XXMeta Information
In Line<citetitle>

In-Line
Personal Information<city>

In-Line
Table<colspec>XXTable
Operating Environment<command>XXIn-Line
In Line<comment>

In-Line
Operating Environment<computeroutput>XXIn-Line
Copyright Legal<copyright>XXIn-Line
Personal Information<country>

In-Line
Meta Information<edition>

In-Line
Meta Information<date>

In-Line
Personal Information<email>XXIn-Line
In Line<emphasis>XXIn-Line
Table<entry>XXTable
General<example>

In-Line
Graphics<figure>

Graphics
Operating Environment<filename>

In-Line
Personal Information<firstname>

In-Line
General<firstterm>

In-Line
General<footnote>

Link
Operating Environment<function>

In-Line
Glossary<glossary>

Nested Element
Glossary<glossdef>

In-Line
Glossary<glossterm>

In-Line
Graphics<graphic>

Graphics
User Interfaces<guibutton>XXIn-Line
User Interfaces<guiicon>XXIn-Line
User Interfaces<guilabel>XXIn-Line
User Interfaces<guimenu>XXIn-Line
User Interfaces<guimenuitem>XXIn-Line
User Interfaces<guisubmenu>XXIn-Line
In Line<highlight>

In-Line
Copyright Legal<holder>

In-Line
Graphics<imageobject>

Graphics
Graphics<imagedata>

Graphics
Index<index>XXIndex
Index<indexentry>XXIndex
Index<indexterm>XXIndex
General<informalexample>

In-Line
Table<informaltable>

Table
Graphics<inlinegraphic>

Graphics
Graphics<inlinemediaobject>

Graphics
List<itemizedlist>XXLists
User Interfaces<keycap>XXIn-Line
User Interfaces<keycombo>XXIn-Line
User Interfaces<keysym>XXIn-Line
Copyright Legal<legalnotice>

Nested Element
Link<link>XXLink
List<listitem>

Lists
Formatting<literal>

In-Line
Formatting<literallayout>

In-Line
Formatting<markup>

In-Line
Graphics<mediaobject>

Graphics
List<member>

Lists
User Interfaces<menuchoice>XXNested Element
Admonition<note>

Link
Personal Information<orgname>XXIn-Line
Link<olink>XXLink
Operating Environment<option>

In-Line
List<orderedlist>XXLists
General<para>XXIn-Line

<part>

Top-Level Element
Meta Information<partintro>

Top-Level Element
In Line<phrase>

In-Line
Personal Information<postcode>

In-Line
Component<preface>

Top-Level Element
Index<primary>XXIndex
Index<primaryie>XXIndex
Procedure<procedure>

In-Line
Meta Information<publisher>

Nested Element
Meta Information<releaseinfo>

Meta Information
In Line<remark>

In-Line
General<replaceable>

In-Line
Revision<revhistory>

Nested Element
Revision<revision>

Nested Element
Revision<revnumber>

Nested Element
Table<row>XXTable
Graphics<screeninfo>

Graphics
Graphics<screenshot>

Graphics
Index<secondary>XXIndex
Index<secondaryie>XXIndex
Sections<sect1>XXSections
Sections<sect2>XXSections
Sections<sect3>XXSections
Sections<sect4>XXSections
Sections<sect5>

Sections
Index<see>

Index
Index<seealso>

Index
Procedure<step>

In-Line
In Line<subscript>XXIn-Line
In Line<superscript>XXIn-Line
Personal Information<surname>

In-Line
Operating Environment<systemitem>

In-Line
Table<table>XXTable
Table<tbody>XXTable
List<term>XXLists
Index<tertiary>

Index
Index<tertiaryie>

Index
Graphics<textobject>

Graphics
Table<tgroup>XXTable
Table<thead>XXTable
Admonition<tip>

In-Line
General<title>XXIn-Line
Link<ulink>XXLink
User Interfaces<userinput>

In-Line
List<variablelist>XXLists
List<varlistentry>XXLists
Admonition<warning>

In-Line
Link<xref>XXLink
Personal Information<year>

In-Line
+ + + + Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/supported_tag_table.html ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/tag_usage.html URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/tag_usage.html?rev=1208093&view=auto ============================================================================== --- incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/tag_usage.html (added) +++ incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/tag_usage.html Tue Nov 29 21:37:58 2011 @@ -0,0 +1,317 @@ + + + + + + + +

DocBook tags in OpenOffice.org

+ + +

Contents

+
    +
  1. Top Level Elements
  2. +
  3. Meta Information
  4. +
  5. Nested Elements
  6. +
  7. In-Line Elements
  8. +
  9. Sections
  10. +
  11. Tables
  12. +
  13. Lists
  14. +
  15. Links
  16. +
  17. Graphics
  18. +
  19. Index
  20. +
+ +
+ +

+For the following instructions to work, ensure that the DocBook stylesheets have been enabled. See the User Guide if this has not already been done. Currently the stylesheets only support <article> and <chapter> as top-level elements.

+

+The Stylist and Navigator also need to be displayed: +

    +
  • Press F11 to display the Stylist
  • +
  • Depending on the DocBook tag to be used, the following options are available:
  • +
      +
    • Select either Custom Styles or All Styles in the Stylist combo-box
    • +
    • Click either the Paragraph Styles icon (first in the left on the Stylist) or the Character Styles icon (second from the left on the Stylist)
    • +
    +
  • Press F5 to display the Navigator
  • +
  • The Headings tab can be expanded to navigate through the DocBook sections of the document.
  • +
+

+ +
+ +

1. Top-Level Elements

+ + +

To import an existing Article or Chapter

+

+ In the File Open dialog select the appropriate DocBook filter (Article or Chapter) in the File Type combo-box. An existing DocBook document can then be imported to OpenOffice.org. +

+ +

To export an Article or Chapter

+

+ Similarly, in the File Save As dialog select the appropriate DocBook filter in the File Type combo-box.
+ NOTE: It is possible with the current filter to import an article and export it as a chapter, or go from chapter to article. +

+ +

Creating an Article or Chapter

+

+ It is possible to create and save a new DocBook document in OpenOffice.org. +

    +
  • Go to File -> Open
  • +
  • Select OpenOffice Text Document Template (*.stw) as the File Type
  • +
  • Open the DocBookTemplate.stw (downloaded when enabling the DocBook stylesheets)
  • +
  • Begin entering DocBook content as described in the sections below.
  • +
  • Export the document as either a DocBook Chapter or Article
  • +
+

+ +
+

2. Meta Information

+ +

+ The info sections currently supported match the top-level elements: <articleinfo> and <chapterinfo> +

+

Creating an Articleinfo

+

+ The ArticleInfo can contain the meta information about the Article, such as author details and copyright. +

    +
  • The cursor should be at the top of the document
  • +
  • Open the Insert Section dialog.
  • +
  • Set the name of the new section to ArticleInfo and Insert
  • +
  • Go to Custom Paragraph styles in the Stylist and select Document Title
  • +
  • Enter the document title
  • +
  • Create the Authorgroup (this is an example of using nested elements):
  • +
      +
    • Go to All Character styles in the Stylist and select Default
    • +
    • Press return to create a new line and enter the first author's name
    • +
    • Highlight the author's name
    • +
    • In the Insert Bookmark dialog enter author_0
    • +
    • Repeat the above 3 lines to create the second author's name, this time using author_1
    • + +
    • Create a new line above the author names
    • +
    • Highlight both the names and the empty line above them
    • +
    • In the Insert Bookmark dialog enter authorgroup_0
    • +
    +
  • In the File Save As dialog, export the document as a DocBook Article.
  • +
+ The above steps can also be followed to create a Chapterinfo, replacing Chapter for Article were necessary. +

+ +
+

3. Nested Elements

+ +

Early in the DocBook project there were difficulties mapping nested DocBook XML elements to the internal OpenOffice.org XML format. An example of how nested tags are now supported is the menuchoice element that can contain several guimenu elements. +

+

+ NOTE: This is the initial fix for the problem of nesting DocBook XML tags in OpenOffice.org. The main purpose was to retain the information on a round-trip import and export of a DocBook document. It is not ideally suited to creating DocBook content in OpenOffice.org.
+

+

Nesting Guimenus and Guimenuitem inside a Menuchoice

+
    +
  • Press return to create a new paragraph
  • +
  • Go to Custom Character styles in the Stylist and select Guimenu
  • +
  • Enter the Guimenu text
  • +
  • Select Guimenuitem in the Stylist
  • +
  • Enter the Guimenuitem text
  • +
  • Highlight the Guimenu and Guimenuitem text
  • +
  • In the Insert Bookmark dialog enter the text menuchoice_0 and click OK
  • +
+

+ OpenOffice.org bookmarks with reserved names are used to represent the parent element when nesting tags. The convention used is to follow the element name by an underscore and a number. The first element in the document will be numbered 0 (e.g. menuchoice_0) and subsequent elements of the same type will increment this number (e.g. menuchoice_1 menuchoice_2 etc.). For another example of how to use nested tags, see Meta Information where an Authorgroup is used to contain Author's. +

+ + +
+

4. In-Line Elements

+ +

DocBook in-line elements are, in general, mapped to OpenOffice.org Custom Styles. +

+

+ The following instructions show how to create a DocBook subscript element. +

    +
  • Go to Custom Character styles in the Stylist and select Subscript
  • +
  • Enter the subscript text
  • +
+ The same procedure can be used for all of the DocBook Custom Character styles. +

+ +
+

5. Sections

+ +

Initially the DocBook project used OpenOffice.org sections to enforce the nesting of DocBook sections. Feedback has shown that authors wish to use the common word processing styles such as Heading1, Heading2, etc. The following instructions describe how to create a <sect1> that contains a <sect2> +

+
    +
  • Select All Styles in the Stylist combo-box
  • +
  • Click the Paragraph Styles icon (first in the left on the Stylist)
  • +
  • Double-click the Heading 1 style
  • +
  • Enter the text to be the <sect1> title
  • +
  • All the text below this heading will now be the content of the DocBook <sect1>
  • +
  • Enter other DocBook styles, tables, etc.
  • +
  • Enter other DocBook styles, tables, etc. to be included in <sect1>
  • +
      +
    • Double-click the Heading 2 style
    • +
    • Enter the text to be the <sect2> title
    • +
    • All the text below this heading will now be the content of the DocBook <sect2>
    • +
    • Enter other DocBook styles, tables, etc. to be included in <sect2>
    • +
    +
  • This nesting of DocBook sect's using OpenOffice headings can go as far as <sect4> / Heading 4
  • +
+ + +
+

6. Tables

+ +

+ Formal and Informal DocBook tables are represented by a standard OpenOffice.org tables.
+
+ Creating a Table +

    +
  • Go to Insert -> Table...
  • +
  • Set the table properties using the Insert Table dialog
  • +
  • The table name will become the table's id
  • +
  • Fill in the content of the table
  • +
  • Right-click on the table, and enter the table's <title> as the Caption
  • +
+

+ Creating an Informaltable +

An <informaltable> is constructed in the same fashion as the formal table above, the only difference is that the table Caption is not specified.

+ + +
+

7. Lists

+ +

+ The various DocBook lists are represented by custom and standard OpenOffice.org list styles. +

+

Creating a Varlist containing Varlistentrys

+
    +
  • Select Custom Styles in the Stylist combo-box
  • +
  • Click the Paragraph Styles icon (first in the left on the Stylist)
  • +
  • Double-click the VarList Term style
  • +
  • Enter text to be contained in the varlist term
  • +
  • Press the return key to enter text in the next varlist term
  • +
+ +

Creating an Orderedlist containing Listitems

+
    +
  • Toggle the numbering to on by clicking the Numbering On/Off icon
  • +
  • Enter text to be contained in the listitem
  • +
  • Press the return key to enter text in the next listitem
  • +
+ +

Creating an Unorderedlist containing Listitems

+
    +
  • Toggle the bullets to on by clicking the Bullets On/Off icon
  • +
  • Enter text to be contained in the listitem
  • +
  • Press the return key to enter text in the next listitem
  • +
+ +
+

8. Links

+ +

The different methods of linking available in DocBook are supported in OpenOffice.org +

+ + + +

How to create a Footnote

+

+

    +
  • Format the properties of the footnote in the Insert Footnote dialog.
  • +
  • Press OK and enter the footnote text at the bottom of the OOo page.
  • +
  • +
  • +
  • +
+ TBD +

+ +

How to create a Note

+

+

    +
  • Go to Insert -> Note...
  • +
  • Enter the text and click OK.
  • +
  • The text will be exported as <note> <remark> your text here </remark> </note>
  • +
+

+ +

How to create an Xref

+

+ There is support for <xref> with a linkend attribute. If the element to be referenced does not already have an id attribute then an id can be created with an OpenOffice.org cross-reference.

+ Create an id attribute for a <sect1> +

    +
  • Highlight the sect1 title
  • +
  • Go to Insert -> Cross-reference...
  • +
  • Set Type to Set Reference
  • +
  • Set Name to the desired value of the id attribute
  • +
  • Click Insert
  • +
+ Create the <xref> +
    +
  • Place cursor where the <xref> is to be located
  • +
  • Go to Insert -> Cross-reference...
  • +
  • Set Type to Insert Reference
  • +
  • From Selection choose the id for the <sect1> (this corresponds to the linkend attribute)
  • +
  • Choose Reference from the Format list.
  • +
  • Click Insert
  • +
+

+ +

Link, Ulink and Olink

+

+ The filter has round trip support for importing and exporting DocBook links. +

+ + +
+

9. Graphics

+ +

+

+

How to create a MediaObject

+

+ TBD +

+ +
+

10. Index

+ +

How to create an Indexterm

+

+

    +
  • If the document does not already contain any DocBook sections see Sections.
  • +
  • Highlight the section title
  • +
  • Go to Insert -> Indexes and Tables -> Entry...
  • +
  • Set Index to Alphabetical Index
  • +
  • Set 1st Key to the desired content of <primary>
  • +
  • Set 2nd Key to the desired content of <secondary>
  • +
  • Click Insert
  • +
+

+

+ NOTE: After discussions with authors the decision was made to only support simplified indexterms in the future. Few authors use spanning indexterms with startofrange and endofrange values or reference elements with a zone attribute. +

+ +

How to create an Index

+

+ At present it is not possible to create a DocBook index in OpenOffice.org. However, the import and export filters should retain any index tags in an existing DocBook document. +

+ + + + Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/tag_usage.html ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/temp_test_only.html URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/temp_test_only.html?rev=1208093&view=auto ============================================================================== --- incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/temp_test_only.html (added) +++ incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/temp_test_only.html Tue Nov 29 21:37:58 2011 @@ -0,0 +1,252 @@ + + +DocBook Filters - Read and write docbook xml using OpenOffice.org + + + + + + + +

DocBook Filters - Read and write docbook xml using OpenOffice.org

+ +

Goal is to explore the possibility of using OpenOffice.org as a WYSIWYG editor of XML content. +The principle is to edit structured documents using styles. These styles are then transformed to XML tags on export.

+ +

This page shows how to enable and use the DocBook filters. It also shows the location of the stylesheets so that users can download and use the latest transformations.

+ + +

Initially the project used OpenOffice.org sections to enforce nesting of DocBook sections. +Feedback has shown that authors wish to use the common word processing styles such as Heading1, Heading2, etc. The stylesheets and templates shipped with OOo1.1 Beta use OpenOffice.org sections. +Links are available below for stylesheets which use OOo headings and instructions on how to install these stylesheets. +Stylesheets currently only support DocBook Articles. Book and Chapter support is planned.

+ + +

Currently stylesheets are packaged in a JAR. The content of the JAR is explained later in this document. It is planned that future OOo will be able to use the import and export XSLTs directly.

+ + +

To see what is available and get an impression of how it works look at :

+ + +

    +
  1. A Sample DocBook Document
  2. +
  3. The corresponding Writer (.sxw) file after importing the docbook file.
    Note : Nested sections supported. See applied or custom styles in the stylist for DocBook tags which have been supported.
  4. + +
+ + +

Note : See also Eric Bellot's OOo2sdbk

+ + + +

How to Enable DocBook in OpenOffice1.1 Beta

+ +

The DocBook filters are installed during OpenOffice.org setup by selecting "Custom Installation" and in the "Optional Components" section, selecting the "Mobile Device Filters".

+ +

To enable the DocBook filter, the following file must be edited:
<OOo Install Dir>/share/registry/data/org/openoffice/Office/TypeDetection.xcu;

+ + +
    +
  • Search for the line <node oor:name="DocBook File" oor:op="replace">
  • +
  • Before the corresponding </node> tag add the following lines:
  • +
+
    + <prop oor:name="Installed" oor:type="xs:boolean"> +
      + <value>true</value> +
    + </prop> +
+
    +
  • Similarly for XHTML except search for the line <node oor:name="XHTML File" oor:op="replace">
  • +
  • Similarly for Flat XML File except search for the line <node oor:name="Flat XML File" oor:op="replace">
  • +
+ +

Once the filter has been enabled, run OOo to see DocBook available in the OpenOffice.org "File of Type" comb-box in both the Open and Save/As dialogs. Hint : Type D in the "File of Type" combo-box maybe more than once.

+ +

NOTE : In order for the Java based filters to work correctly, and Java Runtime Environment needs to be specified during setup. +JRE1.4 or greater is recommended as it contains an XML Parser (Crimson) and an XSLT processor (Xalan). +JRE1.3 can also be used, if a parser e.g. Xerces or Crimson, and the Xalan XSLT processor are made available.

+ + + + +

Using OpenOffice.org to create and edit DocBook XML

+ +

Creating a DocBook Template

+ +It is not possible to use a predefined template to supply the DocBook styles in OpenOffice.org. To do this you must do the following: + +
    + + + +
  • Download the associated template
  • + +
  • Open the template on OOo
  • +
  • Press F11 and choose 'All Styles', so that all available DocBook styles are displayed.
  • +
+ +

Review the UserGuide for information on using the filter.

+ + + + +

Sections/Headings

+ +

How to change the Stylesheet

+ +

The docbook filter uses the XMerge framework's XSLT processing functionality. The docbook.jar contains a set of two XSLT style-sheets, one for transforming from docbook to OpenOffice and one for transforming from OpenOffice to docbook.

+ +

The file also contains a converter.xml file in the META-INF directory that contains information describing the supported mime-types, the style-sheet names and the XMerge plugin that it uses.

+ +

To make changes:

+
    +
  • Create a temp directory. +
      +
    • mkdir temp
    • +
  • +
  • Unpack the jar to the temp directory: +
      +
    • jar -xvf docbook.jar temp
    • +
  • +
  • This will produce the following files in the temp directory: +
      +
    • META-INF/MANIFEST.MF
    • +
    • META-INF/converter.xml
    • + +
    • sofftodocbook.xsl
    • +
    • docbooktosoff.xsl
    • +
  • +
+ +

The two stylesheets can now be edited as required, or download the latest copies from here.

+ +

Repacking the jar:

+
    +
  • cd temp
  • +
  • jar -cvf ../docbook.jar *
  • +
  • Copy the jar to <OOo installation>/program/class directory +
  • Restart OpenOffice.org +
+ +

For example, to use the new XSLT stylesheets, replace the stylesheets in temp with the downloaded versions. The converter.xml file contains info regarding the file conversions that the filter supports. This information is used by XMerge when a conversion has been requested.

+
    +<converters> +
      + <converter type="staroffice/sxw" version="1.0"> +
        + <converter-display-name> +
          + XSLT Transformation sxw +
        + </converter-display-name> +
      +
        + <converter-description> +
          + Converter which performs xslt transformations +
        + </converter-description> +
      +
        + <converter-vendor> +
          + OpenOffice.org +
        + </converter-vendor> +
      +
        + <converter-class-impl> +
          + org.openoffice.xmerge.converter.xml.xslt.PluginFactoryImpl +
        + </converter-class-impl> +
      +
        + <converter-xslt-serialize> +
          + sofftodocbookheadings.xsl +
        + </converter-xslt-serialize> +
      +
        + <converter-xslt-deserialize> +
          + docbooktosoffheadings.xsl +
        + </converter-xslt-deserialize> +
      +
        + <converter-target type="application/x-docbook" /> +
      + </converter> +
    +</converters> +
+ +

Currently Supported Tags

+ +

Click here to obtain a list of currently supported DocBook tags.

+ + +

ToDo

+
    +
  • Increase coverage of supported DocBook tags
  • +
  • XML Entity support. Entity references are lost currently. It may be possible to preserve them by treating them as fields.
  • +
  • ArticleInfo - Initially was going to use document properties but too many tags so this would probably be another section.
  • +
  • Images. (We have placeholders for required information).
  • +
  • Hyperlinks.
  • +
  • Chapters
  • +
  • References
  • +
+ + +

Limitations

+

These are limitations which should be highlighted but are not blockers. In fact, sufficient interest in this project should drive requirements for enhancements.

+ +

- No support in OOo for user as to which styles (tags) to use when. Must create and follow guidelines.

+ +

- No validation for export.

+ + +

Open Issues

+
    +
  • Do not support nested tags in text spans. +
      + e.g Use: +
        + <menuchoice><guimenu>File</guimenu><guimenuitem>New</guimenuitem></menuchoice> +
      + to which in HTML appears as: +
        + Use File ->New +
      +
    +
  • +
  • Importing comments (Parser ignores, may have to use comment tag).
  • +
  • Nested lists are split into three separate lists in SO and have to be exported as three separate lists. Breaks the round trip.
  • +
  • Styles are defined in the import stylesheet.
  • +
  • Would like to be able to import into an existing template.
  • +
+ + + + + + + + + + +
+ +
+ + + Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docbook/temp_test_only.html ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/XMerge_sdk.pdf URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/XMerge_sdk.pdf?rev=1208093&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/XMerge_sdk.pdf ------------------------------------------------------------------------------ svn:mime-type = application/pdf Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/XMerge_sdk.sxw URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/XMerge_sdk.sxw?rev=1208093&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/XMerge_sdk.sxw ------------------------------------------------------------------------------ svn:mime-type = application/octet-stream Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/XSLTPlugin.pdf URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/XSLTPlugin.pdf?rev=1208093&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/XSLTPlugin.pdf ------------------------------------------------------------------------------ svn:mime-type = application/pdf Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/XSLTPlugin.sxw URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/XSLTPlugin.sxw?rev=1208093&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/XSLTPlugin.sxw ------------------------------------------------------------------------------ svn:mime-type = application/octet-stream Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/xmerge_javadoc.zip URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/xmerge_javadoc.zip?rev=1208093&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/docs/xmerge_javadoc.zip ------------------------------------------------------------------------------ svn:mime-type = application/octet-stream Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/DocBookFilter.zip URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/DocBookFilter.zip?rev=1208093&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/DocBookFilter.zip ------------------------------------------------------------------------------ svn:mime-type = application/octet-stream Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/DocBookTemplate.stw URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/DocBookTemplate.stw?rev=1208093&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/DocBookTemplate.stw ------------------------------------------------------------------------------ svn:executable = * Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/DocBookTemplate.stw ------------------------------------------------------------------------------ svn:mime-type = application/octet-stream Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/InstallerSrc.zip URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/InstallerSrc.zip?rev=1208093&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/InstallerSrc.zip ------------------------------------------------------------------------------ svn:executable = * Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/InstallerSrc.zip ------------------------------------------------------------------------------ svn:mime-type = application/octet-stream Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/XMergeInstall.jar URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/XMergeInstall.jar?rev=1208093&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/XMergeInstall.jar ------------------------------------------------------------------------------ svn:executable = * Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/XMergeInstall.jar ------------------------------------------------------------------------------ svn:mime-type = application/octet-stream Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/docbook.jar URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/docbook.jar?rev=1208093&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/docbook.jar ------------------------------------------------------------------------------ svn:mime-type = application/octet-stream Added: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/docbook_template.sxw URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/docbook_template.sxw?rev=1208093&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/docbook_template.sxw ------------------------------------------------------------------------------ svn:executable = * Propchange: incubator/ooo/ooo-site/trunk/content/xml/xmerge/downloads/docbook_template.sxw ------------------------------------------------------------------------------ svn:mime-type = application/octet-stream