You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by sc...@apache.org on 2007/04/10 20:33:26 UTC
svn commit: r527241 - in /incubator/uima/uimaj/trunk/uima-docbook-tool: ./
build/samples/ properties/ properties/samples/ samples/ samples/titlepage/
samples/top/ styles/common/samples/ styles/uima-style/titlepage/
Author: schor
Date: Tue Apr 10 11:33:24 2007
New Revision: 527241
URL: http://svn.apache.org/viewvc?view=rev&rev=527241
Log:
UIMA-236 reorganize samples into one dir to make adoption easier. Start a HOWTO, add a
shared xinclude.mod file to be referenced as needed
Added:
incubator/uima/uimaj/trunk/uima-docbook-tool/HOW_TO
incubator/uima/uimaj/trunk/uima-docbook-tool/properties/default.docbook.properties
incubator/uima/uimaj/trunk/uima-docbook-tool/samples/
incubator/uima/uimaj/trunk/uima-docbook-tool/samples/build_book-name.xml
- copied unchanged from r526931, incubator/uima/uimaj/trunk/uima-docbook-tool/build/samples/build_book-name.xml
incubator/uima/uimaj/trunk/uima-docbook-tool/samples/local.docbook.properties
- copied, changed from r526931, incubator/uima/uimaj/trunk/uima-docbook-tool/properties/samples/local.docbook.properties
incubator/uima/uimaj/trunk/uima-docbook-tool/samples/titlepage/
- copied from r526931, incubator/uima/uimaj/trunk/uima-docbook-tool/styles/uima-style/titlepage/
incubator/uima/uimaj/trunk/uima-docbook-tool/samples/titlepage/titlepage-html.xml
- copied unchanged from r527212, incubator/uima/uimaj/trunk/uima-docbook-tool/styles/uima-style/titlepage/titlepage-html.xml
incubator/uima/uimaj/trunk/uima-docbook-tool/samples/titlepage/titlepage-pdf.xml
- copied unchanged from r527212, incubator/uima/uimaj/trunk/uima-docbook-tool/styles/uima-style/titlepage/titlepage-pdf.xml
incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/
incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-html-chunked.xsl
incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-html-single.xsl
incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-pdf.xsl
incubator/uima/uimaj/trunk/uima-docbook-tool/xinclude.mod
Removed:
incubator/uima/uimaj/trunk/uima-docbook-tool/build/samples/build_book-name.xml
incubator/uima/uimaj/trunk/uima-docbook-tool/properties/samples/local.docbook.properties
incubator/uima/uimaj/trunk/uima-docbook-tool/styles/common/samples/sample-html-chunked.xsl
incubator/uima/uimaj/trunk/uima-docbook-tool/styles/common/samples/sample-html-single.xsl
incubator/uima/uimaj/trunk/uima-docbook-tool/styles/common/samples/sample-pdf.xsl
incubator/uima/uimaj/trunk/uima-docbook-tool/styles/uima-style/titlepage/titlepage-html.xml
incubator/uima/uimaj/trunk/uima-docbook-tool/styles/uima-style/titlepage/titlepage-pdf.xml
Added: incubator/uima/uimaj/trunk/uima-docbook-tool/HOW_TO
URL: http://svn.apache.org/viewvc/incubator/uima/uimaj/trunk/uima-docbook-tool/HOW_TO?view=auto&rev=527241
==============================================================================
--- incubator/uima/uimaj/trunk/uima-docbook-tool/HOW_TO (added)
+++ incubator/uima/uimaj/trunk/uima-docbook-tool/HOW_TO Tue Apr 10 11:33:24 2007
@@ -0,0 +1,55 @@
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+============================================================
+
+This file contains some tips on how to create documentation using this docbook system.
+
+Recommended editor = XMLBuddy plugin for Eclipse. This will read the docbook dtd,
+plus any customized Entities you might declare, and make them available for
+Eclipse auto-completion and checking.
+
+Entities you declare can be put into shared entity files, and then
+essentially included in other files. See Chapter 22 of the DocBook XSL, the
+Complete Guide, for examples.
+
+
+Step 1: Create a project (if necessary) for your docbook documentation.
+
+Step 2: Organize the documentation into "books", and within books, "chapters".
+
+Step 3: create a file "local.docbook.properties", modelled on samples/local.docbook.properties
+
+
+
+NOTES:
+
+The functionality for xi:include relative linking when the thing being included was
+in a different directory from the includer was broken.
+This showed up in image fileref= attributes being improperly / inconsistently translated
+to src=... attributes in the generated xml. Work-around: give up for now
+in having subdirectories - put all things into one directory. (Note - as
+of April 2007 a bug in this area has been fix and this needs to be retested)
+
+The qandaset functionality works but the FOP processor 0.20.5 seems to have trouble
+handling id= attributes; it's giving an incorrect error message about a duplicate id tag,
+when, in fact, there is no duplicate. Work-around: give up using qandaset - just use
+variablelist instead.
+
+Parameters for Docbook are described in the FO ref:
+http://docbook.sourceforge.net/release/xsl/current/doc/fo/index.html
+
+body.start.indent fails on FOP - use title.margin.left instead
\ No newline at end of file
Added: incubator/uima/uimaj/trunk/uima-docbook-tool/properties/default.docbook.properties
URL: http://svn.apache.org/viewvc/incubator/uima/uimaj/trunk/uima-docbook-tool/properties/default.docbook.properties?view=auto&rev=527241
==============================================================================
--- incubator/uima/uimaj/trunk/uima-docbook-tool/properties/default.docbook.properties (added)
+++ incubator/uima/uimaj/trunk/uima-docbook-tool/properties/default.docbook.properties Tue Apr 10 11:33:24 2007
@@ -0,0 +1,55 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+
+# default version info
+# which version of fop to use
+fop.version = 0.93
+
+# which version of docbook to use
+docbook.xml.version = 4.5
+docbook.xsl.version = 1.72.0
+
+# which version of saxon to use
+saxon.version = 6.5.5
+
+# which version of jai to use
+# jai = Java Advanced Imaging - need by FOP to process included images
+# ########## NOTE only 1.1.3 supported in the autodownload part ########
+jai.version = 1.1.3
+
+# Where all the sources are located
+src.dir = ${basedir}/src
+
+# Location of the docbook files
+docbook.src.dir = ${src.dir}/docbook
+
+# Location of olink info
+olink.dir = ${src.dir}/olink
+
+# Target Directory
+target.dir = ${basedir}/target
+
+# The size of the PDF pages.
+paper.type= Letter
+
+# use saxon version 6.5.5
+saxon.version = 6.5.5
+# We use SAXON as our XSLT processor and this is the custom jar included with
+# the docbook XML distribution.
+xslt-db.jar = saxon653.jar
+
Copied: incubator/uima/uimaj/trunk/uima-docbook-tool/samples/local.docbook.properties (from r526931, incubator/uima/uimaj/trunk/uima-docbook-tool/properties/samples/local.docbook.properties)
URL: http://svn.apache.org/viewvc/incubator/uima/uimaj/trunk/uima-docbook-tool/samples/local.docbook.properties?view=diff&rev=527241&p1=incubator/uima/uimaj/trunk/uima-docbook-tool/properties/samples/local.docbook.properties&r1=526931&p2=incubator/uima/uimaj/trunk/uima-docbook-tool/samples/local.docbook.properties&r2=527241
==============================================================================
--- incubator/uima/uimaj/trunk/uima-docbook-tool/properties/samples/local.docbook.properties (original)
+++ incubator/uima/uimaj/trunk/uima-docbook-tool/samples/local.docbook.properties Tue Apr 10 11:33:24 2007
@@ -24,7 +24,9 @@
# where to get css and styles
+# docbook.tool.project is set to the root of that project
css_styles_prefix = ${docbook.tool.project}/styles/uima-style
# where to get title page and save results
+# basedir is set to the local project's base directory
local.titlepage.dir = ${basedir}/src/styles/titlepage
Added: incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-html-chunked.xsl
URL: http://svn.apache.org/viewvc/incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-html-chunked.xsl?view=auto&rev=527241
==============================================================================
--- incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-html-chunked.xsl (added)
+++ incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-html-chunked.xsl Tue Apr 10 11:33:24 2007
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+-->
+
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ version='1.0'>
+
+ <!-- S A M P L E -->
+
+ <!-- note that xsl:import elements must appear FIRST
+ and their href strings must be literal (no variables allowed) -->
+
+ <!-- import docbook system from the shared uima-docbook-tool project -->
+ <xsl:import href="../../../uima-docbook-tool/tools/docbook-versions/docbook-xsl-1.72.0/html/chunk.xsl" />
+
+ <!-- import the standard uima-style of formatting from the shared uima-docbook-tool project -->
+ <xsl:import href="../../../uima-docbook-tool/styles/uima-style/top/html-chunked.xsl" />
+
+ <!-- The script will generate a title page in ${local.titlepage.dir} -->
+ <!-- this generate xsl file needs to be included here -->
+ <!-- Make sure the path agrees with your setting of ${local.titlepage.dir} in local.docbook.properties -->
+ <xsl:include href="../titlepage/titlepage-html.xsl"/>
+
+</xsl:stylesheet>
Added: incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-html-single.xsl
URL: http://svn.apache.org/viewvc/incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-html-single.xsl?view=auto&rev=527241
==============================================================================
--- incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-html-single.xsl (added)
+++ incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-html-single.xsl Tue Apr 10 11:33:24 2007
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+-->
+
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ version='1.0'>
+
+ <!-- S A M P L E -->
+
+ <!-- note that xsl:import elements must appear FIRST
+ and their href strings must be literal (no variables allowed) -->
+
+ <!-- import docbook system from the shared uima-docbook-tool project -->
+ <xsl:import href="../../../uima-docbook-tool/tools/docbook-versions/docbook-xsl-1.72.0/html/docbook.xsl" />
+
+ <!-- import the standard uima-style of formatting from the shared uima-docbook-tool project -->
+ <xsl:import href="../../../uima-docbook-tool/styles/uima-style/top/html-single.xsl" />
+
+ <!-- The script will generate a title page in ${local.titlepage.dir} -->
+ <!-- this generate xsl file needs to be included here -->
+ <!-- Make sure the path agrees with your setting of ${local.titlepage.dir} in local.docbook.properties -->
+ <xsl:include href="../titlepage/titlepage-html.xsl"/>
+
+</xsl:stylesheet>
Added: incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-pdf.xsl
URL: http://svn.apache.org/viewvc/incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-pdf.xsl?view=auto&rev=527241
==============================================================================
--- incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-pdf.xsl (added)
+++ incubator/uima/uimaj/trunk/uima-docbook-tool/samples/top/sample-pdf.xsl Tue Apr 10 11:33:24 2007
@@ -0,0 +1,50 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+-->
+
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ version='1.0'>
+
+ <!-- S A M P L E -->
+
+ <!-- note that xsl:import elements must appear FIRST
+ and their href strings must be literal (no variables allowed) -->
+
+ <!-- import docbook system from the shared uima-docbook-tool project
+
+
+ I M P O R T A N T
+ Change the ../../../ . . . pattern below to go up enough to
+ reach the directory where uima-docbook-tool project is,
+ relative to the directory where you put this file -->
+
+
+ <xsl:import href="../../../uima-docbook-tool/tools/docbook-versions/docbook-xsl-1.72.0/fo/docbook.xsl" />
+
+ <!-- import the standard uima-style of formatting from the shared uima-docbook-tool project -->
+ <xsl:import href="../../../uima-docbook-tool/styles/uima-style/top/pdf.xsl" />
+
+ <!-- The script will generate a title page in ${local.titlepage.dir} -->
+ <!-- this generate xsl file needs to be included here -->
+ <!-- Make sure the path agrees with your setting of ${local.titlepage.dir} in local.docbook.properties -->
+
+ <xsl:include href="../titlepage/titlepage-pdf.xsl"/>
+
+</xsl:stylesheet>
Added: incubator/uima/uimaj/trunk/uima-docbook-tool/xinclude.mod
URL: http://svn.apache.org/viewvc/incubator/uima/uimaj/trunk/uima-docbook-tool/xinclude.mod?view=auto&rev=527241
==============================================================================
--- incubator/uima/uimaj/trunk/uima-docbook-tool/xinclude.mod (added)
+++ incubator/uima/uimaj/trunk/uima-docbook-tool/xinclude.mod Tue Apr 10 11:33:24 2007
@@ -0,0 +1,46 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+-->
+<!-- xml comments allowed in this file -->
+
+<!-- ================================================================-->
+<!-- This file is incorporated in xml files which have xi:include
+ elements, to allow those files to validate in an XML editor
+ without actually doing the includes -->
+
+<!-- defines xi:include as a valid element for validating editors -->
+<!-- adds it as an element to sub parts of books and chapters. -->
+<!-- This must be referenced by each source file that has xi:include
+ elements, in the file's DOCTYPE declaration,
+ using the syntax
+ lt;!ENTITY % xinclude SYSTEM "../../ . . . /uima-docbook-tool/xinclude.mod">
+ %xinclude; -->
+
+<!ELEMENT xi:include (xi:fallback?) >
+<!ATTLIST xi:include
+ xmlns:xi CDATA #FIXED "http://www.w3.org/2001/XInclude"
+ href CDATA #REQUIRED
+ parse (xml|text) "xml"
+ encoding CDATA #IMPLIED >
+
+<!ELEMENT xi:fallback ANY>
+<!ATTLIST xi:fallback
+ xmlns:xi CDATA #FIXED "http://www.w3.org/2001/XInclude" >
+
+<!ENTITY % local.chapter.class "| xi:include">
+<!ENTITY % local.book.class "| xi:include">